我有以下代码:
<s:BorderContainer id="myBorder"
width="78" height="78"
horizontalCenter="0"
>
<s:Scroller id="myScroller" horizontalScrollPolicy="off" >
<s:TileGroup id="thingyList"
height="78"
focusEnabled="true"
horizontalGap="4"
verticalGap="4"
mouseOver="thingyList_mouseOverHandler(event)"
paddingBottom="0" paddingLeft="0" paddingRight="0" paddingTop="0"
requestedColumnCount="3"
requestedRowCount="3"
maxHeight="78"
maxWidth="78"
bottom="row1:3"
verticalScrollPosition="70"
horizontalAlign="center"
verticalAlign="middle"
clipAndEnableScrolling="true"
/>
</s:Scroller>
</s:BorderContainer>
我遇到的问题是,当项目被添加到tileGroup时,tile组的垂直显示会溢出其边界,从而显示+ - 3 1/2行数据。!
这真让我疯了!任何人的想法?
谢谢!,
MCE
答案 0 :(得分:1)
Scroller在Spark架构中很棘手。
给Scroller一个明确的高度和宽度;将TileGroup设置为100%的高度和宽度。
<s:Scroller id="myScroller" horizontalScrollPolicy="off" height="78" width="78" >
<s:TileGroup id="thingyList"
height="100%"
focusEnabled="true"
horizontalGap="4"
verticalGap="4"
mouseOver="thingyList_mouseOverHandler(event)"
paddingBottom="0" paddingLeft="0" paddingRight="0" paddingTop="0"
requestedColumnCount="3"
requestedRowCount="3"
maxHeight="78"
maxWidth="78"
bottom="row1:3"
verticalScrollPosition="70"
horizontalAlign="center"
verticalAlign="middle"
clipAndEnableScrolling="true"
width="100%"
/>
</s:Scroller>