0 Replies Latest reply on Jun 2, 2007 11:30 PM by noachic

    List based classes with locked rows scrolling bug

    noachic
      Found on DataGrid and then verified on List as well.
      When the list control specified a lockedRowCount that is greater than 0 (for DataGrid, this is almost all the time since there is a header row), if you do pagescroll, everything seem OK, but if you do linescroll or mousewheel scroll (especially when you do dragging on the scroll bar quickly), then the first row of the content and the header row will appear to be buggy (e.g. showing incorrect row data. anybody else seen similar issue?

      testing code:

      <mx:Script>
      <![CDATA[
      [Bindable]
      public var selectedItem:Object;
      ]]>
      </mx:Script>


      <mx:Model id="mystates">
      <states>
      <state label="AAA" data="AAA"/>
      <state label="BBB" data="BBB"/>
      <state label="CCC" data="CCC"/>
      <state label="DDD" data="DDD"/>
      <state label="EEE" data="EEE"/>
      <state label="FFF" data="FFF"/>
      <state label="GGG" data="GGG"/>
      <state label="HHH" data="HHH"/>
      <state label="III" data="III"/>
      <state label="JJJ" data="JJJ"/>
      <state label="KKK" data="KKK"/>
      <state label="LLL" data="LLL"/>
      <state label="MMM" data="MMM"/>
      <state label="OOO" data="OOO"/>
      <state label="PPP" data="PPP"/>
      <state label="QQQ" data="QQQ"/>
      <state label="RRR" data="RRR"/>
      <state label="SSS" data="SSS"/>
      <state label="TTT" data="TTT"/>
      <state label="UUU" data="UUU"/>
      <state label="VVV" data="VVV"/>
      <state label="WWW" data="WWW"/>
      <state label="XXX" data="XXX"/>
      <state label="YYY" data="YYY"/>
      <state label="ZZZ" data="ZZZ"/>
      </states>
      </mx:Model>

      <mx:Panel title="List Control Example" height="75%" width="75%"
      paddingTop="10" paddingBottom="10" paddingLeft="10" paddingRight="10">

      <mx:Label text="Select a state to see its abbreviation."/>

      <mx:List id="source" width="100%" color="blue"
      dataProvider="{mystates.state}"
      change="this.selectedItem=List(event.target).selectedItem" lockedRowCount="1"/>

      <mx:VBox width="100%">
      <mx:Label text="Selected State: {selectedItem.label}"/>
      <mx:Label text="State abbreviation: {selectedItem.data}"/>
      </mx:VBox>

      </mx:Panel>