Hi,
I have the following declaration inside my custom component:
ActionScript Code:
private static var defaultStyles:Object = {
highLightImage:null,
bulletImage:null,
styleSheet: null,
embedFonts:false
}
public static function getDefaultStyles():Object {
return defaultStyles;
/*with this doen't work either UIComponent.mergeStyles(defaultStyles, UIComponent.getStyleDefinition());*/
}
when I set the style for the component from the fla root, before creating an instance of it:
ActionScript Code:
StyleManager.setComponentStyle(ContentDisplay, "styleSheet", sheet);
then the component fails to get the style from draw() method when it calls
ActionScript Code:
getStyleValue("styleSheet");
The component constructor is executing it's parent correctly as specification says.
if I set the style after the component is instanced then it can retieve the style correctly..
what can I do? What I am missing? Please help..
thanks.