
转载请保持文章完整性!
本文链接地址:http://blog.desizen.com/4lone/533.html
主页:joel's blog
这个例子进行的是Tourdeflex:UI Controls:ListControls:TileList
文中用到的图片下载地址:点此下载,下载后整个images文件夹放到src目录即可.
简介:
The TileList control displays a number of items laid out in tiles. It displays a scroll bar on one of its axes to access all items in the list, depending on the direction property. You can set the size of the tiles by using rowHeight and columnWidth properties. Alternatively, Flex measures the item renderer for the first item in the dataProvider and uses that size for all tiles.
例子:
<?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" verticalAlign="top" horizontalAlign="center" backgroundGradientColors="[0x000000,0x323232]" paddingTop="0" paddingBottom="0" viewSourceURL="srcview/index.html"> <mx:Panel title="TileList Control" layout="vertical" width="360" color="0xffffff" borderAlpha="0.15" paddingTop="10" paddingRight="10" paddingBottom="10" paddingLeft="10" horizontalAlign="center"> <mx:Label width="100%" textAlign="center" color="0x323232" text="A TileList control displays items in rows and columns."/> <mx:TileList id="AppSelection" width="300" height="158" color="0x323232" columnWidth="126" maxColumns="2" > <mx:dataProvider> <mx:Array> <mx:Object label="Backpack" icon="@Embed('images/backpack.jpg')"/> <mx:Object label="Compass" icon="@Embed('images/compass.jpg')"/> <mx:Object label="Goggles" icon="@Embed('images/goggles.jpg')"/> <mx:Object label="Boots" icon="@Embed('images/boots.jpg')"/> <mx:Object label="Helmet" icon="@Embed('images/helmet.jpg')"/> </mx:Array> </mx:dataProvider> </mx:TileList> </mx:Panel> </mx:Application>
标签:FLEX, TileList, TourDeFlex, 例子
