Adobe FLEX 2 - CREATING AND EXTENDING COMPONENTS Manual page 90

Creating and extending flex 2 components
Hide thumbs Also See for FLEX 2 - CREATING AND EXTENDING COMPONENTS:
Table of Contents

Advertisement

If you define a type selector for a superclass of the custom control, and for the custom control
itself, Flex ignores any conflicting settings from the type selector for the superclass, as the
following example shows:
<?xml version="1.0"?>
<!-- mxml/MainStyleOverrideUsingCBTypeSelConflict.mxml -->
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
xmlns:MyComp="myComponents.*">
<mx:Style>
ComboBox {
color: red;
openDuration: 1000;
fontSize: 15;
}
StateComboBoxWithStyleProps {
color: green;
}
</mx:Style>
<MyComp:StateComboBoxWithStyleProps/>
<mx:ComboBox/>
</mx:Application>
In this example, the StateComboBox control uses green text, and the values for the
and
styles specified in the type selector for the ComboBox control.
openDuration
90
Creating Simple MXML Components
fontSize

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLEX 2 - CREATING AND EXTENDING COMPONENTS and is the answer not in the manual?

Questions and answers

Table of Contents