Flex Gumbo中如何通过requestedRowCount属性设置FxList行数的例子

By Minidxer | July 16, 2009

接下来的例子演示了Flex Gumbo中如何通过requestedRowCount属性,设置FxList行数。

让我们先来看一下Demo可以点击这里察看源代码):


下面是完整代码(或点击这里察看):

Download: main.mxml
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <FxApplication name="FxList_layout_VerticalLayout_requestedRowCount_test"
  3.         xmlns="http://ns.adobe.com/mxml/2009"
  4.         backgroundColor="white">
  5.  
  6.     <FxList id="list"
  7.             horizontalCenter="0"
  8.             verticalCenter="0">
  9.         <layout>
  10.             <VerticalLayout requestedRowCount="6"
  11.                     gap="0"
  12.                     horizontalAlign="contentJustify" />
  13.         </layout>
  14.         <dataProvider>
  15.             <ArrayCollection>
  16.                 <String>1. The</String>
  17.                 <String>2. Quick</String>
  18.                 <String>3. Brown</String>
  19.                 <String>4. Fox</String>
  20.                 <String>5. Jumps</String>
  21.                 <String>6. Over</String>
  22.                 <String>7. The</String>
  23.                 <String>8. Lazy</String>
  24.                 <String>9. Dog</String>
  25.             </ArrayCollection>
  26.         </dataProvider>
  27.     </FxList>
  28.  
  29. </FxApplication>
代码:Peter deHaan 翻译/整理/编译:中文Flex例子

Topics: FxList, Gumbo | No Comments » | Tags: , , ,

Search Posts