NavigatorCont是怎么使用皮肤的呢?找了好久,没有找到。
最后不得不换成了一个Button后引用皮肤的。
无意间又看到了这个的答案,这才整理了一下!
是在一个外国的网站上看到的。。
定义的NavigatorContent:
<mx:TabNavigator x="216" y="149" width="671" height="301" tabStyleName="tab" > <s:NavigatorContent label="test" width="100%" height="100%" backgroundColor="red" chromeColor="red" contentBackgroundColor="red" focusColor="red" rollOverColor="red" symbolColor="red" > </s:NavigatorContent> <s:NavigatorContent label="test" width="100%" height="100%" chromeColor="#F31313" contentBackgroundColor="#ED1010" backgroundColor="#EE1515"> </s:NavigatorContent> </mx:TabNavigator>
tabStyleName="tab" 是引用了一个样式:
.tab{ upSkin:ClassReference('ui.skins.ufmButtonBg2skin'); overSkin:ClassReference('ui.skins.ufmButtonBg2skin'); downSkin:ClassReference('ui.skins.ufmButtonBg2skin'); disabledSkin:ClassReference('ui.skins.ufmButtonBg2skin'); selectedUpSkin:ClassReference('ui.skins.ufmButtonBg2skin'); selectedOverSkin:ClassReference('ui.skins.ufmButtonBg2skin'); selectedDownSkin:ClassReference('ui.skins.ufmButtonBg2skin'); selectedDisabledSkin:ClassReference('ui.skins.ufmButtonBg2skin'); cornerRadii: 5, 5, 0, 0; borderColors: #EE1515, #EE1515; overBorderColors: #EE1515, #EE1515; selectedBorderColors: #EE1515, #EE1515; borderThickness: 1; borderAlpha: 1; fillColors: #EE1515, #EE1515; fillAlphas: 1, 1; fillColorRatios: 0, 255; overFillColors: #EE1515, #EE1515; overFillAlphas: 1, 1; overFillColorRatios: 0, 255; selectedFillColors: #EE1515, #EE1515; selectedFillAlphas: 1, 1; selectedFillColorRatios: 111, 255; highlightAlphas: 0, 0; color: #EE1515; textRollOverColor: #000000; fontSize: 13; }
这样,NavigatorContent就引用了皮肤
是在看到的网站!