[Flex4] VGroup 出現卷軸,使用VScrollBar
2010/11/18
筆記一下..
因為在Flex 3 中 的 VBox 只要設定 verticalScrollPolicy 就會出現…
但是在 Flex4(Flash Builder 4) 已經不見了…
現在的做法是改成 使用 VScrollBar 這物件去做控制.
這作法雖然麻煩點..
但是可以自訂的能力會變得更高…
怕忘記..
筆記一下…
<?xml version="1.0" encoding="utf-8"?> <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600"> <fx:Declarations> <!-- Place non-visual elements (e.g., services, value objects) here --> </fx:Declarations> <s:VGroup x="128" y="85" id="myGroup" width="200" height="200" gap="10" clipAndEnableScrolling="true"> <s:Button label="x1" /> <s:Button label="x2" /> <s:Button label="x3" /> <s:Button label="x4" /> <s:Button label="x5" /> <s:Button label="x6" /> <s:Button label="x7" /> <s:Button label="x8" /> <s:Button label="x9" /> <s:Button label="x10" /> <s:Button label="x11" /> <s:Button label="x12" /> <s:Button label="x13" /> </s:VGroup> <s:VScrollBar viewport="{myGroup}" height="200" x="312" y="85" /> </s:Application>
預覽:
讚一下:
標籤:
Flex
|
This entry was posted on 下午6:51
and is filed under
Flex
.
You can follow any responses to this entry through
the RSS 2.0 feed.
You can leave a response,
or trackback from your own site.
訂閱:
張貼留言 (Atom)
0 意見:
張貼留言