1 Reply Latest reply on Jun 5, 2010 1:36 PM by UbuntuPenguin

    TileLayout: First item in a row

    jsd99

      I am using TileLayout on a Spark List.  Is there a way for an individual itemRenderer to know that it is the first item in a row?  Recycling would not be an issue - all the list items are on screen simultaneously.

        • 1. Re: TileLayout: First item in a row
          UbuntuPenguin Level 4

          If the class implement IDropInListItemRenderer , then you can access the listData and use the rowIndex property.  If the class doesn't implement it , you will have to look at the interface and implement it yourself.  Once you get it you can do something like this.

           

          public function someFunct():void

          {

               if ( this.listData.rowIndex == 0 )

               {

                    trace("Hoorah !");

               }

          }