2010-09-30 154 views
0

滚动条未显示的示例应用程序。在基于约束的布局中使用滚动器是否有任何理智的方法?嵌套滚动条不起作用

<?xml version="1.0" encoding="utf-8"?> 

<s:HGroup left="0" right="0" top="0" bottom="0">     
     <s:Scroller left="0" right="0" top="0" bottom="0"> 
      <s:VGroup>   
       <s:BorderContainer borderColor="0" width="500" height="500"/> 
       <s:BorderContainer borderColor="0" width="500" height="500"/> 
       <s:BorderContainer borderColor="0" width="500" height="500"/> 
      </s:VGroup> 
     </s:Scroller>  
</s:HGroup> 

回答

0

找到 “迫使蛮力” 左/右/ WIDT /高度等的每个可能的组合后的溶液

<?xml version="1.0" encoding="utf-8"?> 
<s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009" 
         xmlns:s="library://ns.adobe.com/flex/spark" 
         xmlns:mx="library://ns.adobe.com/flex/mx" 
         width="500" height="400" 
         > 
    <fx:Declarations> 
     <!-- Place non-visual elements (e.g., services, value objects) here --> 
    </fx:Declarations> 

     <s:HGroup left="0" right="0" top="0" bottom="0" > 
     <s:Scroller width="100%" height="100%"> 
      <s:VGroup >   
       <s:BorderContainer borderColor="0" width="500" height="500"/> 
       <s:BorderContainer borderColor="0" width="500" height="500"/> 
       <s:BorderContainer borderColor="0" width="500" height="500"/> 
      </s:VGroup> 
     </s:Scroller> 
     </s:HGroup> 

</s:WindowedApplication>