当mxml页面加载时,我试图隐藏Year2017。我使用可见和includeInLayout属性,但它似乎并没有工作。Flex - 使用visible和includeInLayout隐藏mxml
有人能帮助我吗?
一些代码写上 - Year2017.mxml, Year2016.mxml, Year2015.mxml
MainScreen.mxml
<mx:HBox
<component:PopupOpenerViewStack
id="payeVS"
borderStyle="none"
width="100%"
height="100%"
componentToFocusOn="{controlBar.overviewBut}"
selectedIndex="{ this.mainModel.navigator.selectedIndex }" >
<view1:Year2017
width="100%"
height="100%"
visible="{isVisible}"
includeInLayout="{isVisible}" />
<view1:Year2016
width="100%"
height="100%"/>
<view1:Year2015
width="100%"
height="100%"/>
</component:PopupOpenerViewStack>
</mx:HBox>
你是如何宣称ISVISIBLE?确保它是可绑定的。 –
是的,我做到了。 [Bindable] private var isVisible:Boolean = false;即使我试过硬编码isVisible =“false”和includeInLayout =“false”。 Dint的工作:( – Techie
我认为问题出在组件:PopupOpenerViewStack。如果它使用Flex PopupManager,那么可见和includeInLayout不会帮助,请确认它是否使用adobe的PopupManager。 –