Flash CS3 Documentation |
|||
| Using ActionScript 2.0 Components > Customizing Components > About skinning components > Applying new skins to a component | |||
Once you have created a new skin, you must apply it to a component in a document. You can use the createClassObject() method to dynamically create the component instances, or you can manually place the component instances on the Stage. There are two different ways to apply skins to component instances, depending on how you add the components to a document.
This adds the symbols to the document's library, but doesn't make them visible in the document.
This adds the symbols to the document's library, but doesn't make them visible in the document.
import mx.controls.RadioButton;
createClassObject(RadioButton, "myRadio", 0, {trueUpIcon:"MyRadioTrueUp", label: "My Radio Button"});
This adds the symbols to the document's library, but doesn't make them visible in the document.
onClipEvent(initialize){
trueUpIcon = "MyRadioTrueUp";
}
Flash CS3