Inline Renderer with Complex Objects
<?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" backgroundColor="#EEEEEE"> <mx:ArrayCollection id="answerData"> <mx:Object> <mx:value>Yes</mx:value> <mx:imageSource>a.png</mx:imageSource> </mx:Object> <mx:Object> <mx:value>No</mx:value> <mx:imageSource>a.png</mx:imageSource> </mx:Object> <mx:Object> <mx:value>Maybe</mx:value> <mx:imageSource>a.png</mx:imageSource> </mx:Object> </mx:ArrayCollection> <mx:List id="myList" dataProvider="{answerData}" rowCount="{answerData.length}" variableRowHeight="true" width="80" height="140"> <mx:itemRenderer> <mx:Component> <mx:Image source="{data.imageSource}"/> </mx:Component> </mx:itemRenderer> </mx:List> <mx:Label text="{myList.selectedItem.value}" fontSize="14"/> </mx:Application>