I'm desperately trying to implement custom states with skinnames, but i'm unable to get this to work.
The docs do not have much info about this.
Here's what i've got so far in a custom component derived from UIComponent:
Code:
<mx:Metadata>
[Style (name="fooSkin", type="Class", inherit="no", states="foo")]
[Style (name="barSkin", type="Class", inherit="no", states="bar")]
</mx:Metadata>
<mx:states>
<mx:State name="foo"/>
<mx:State name="bar"/>
</mx:states>
what i'd like to do is create a stateful skin that can use my custom states.
As far as i can tell from the builtin skin code, the skin class check's it's name in the updatedisplaylist function to determine how to draw itself.
I'm setting the style for the component as follows:
Code:
.myStyle {
fooSkin: ClassReference('MySkin');
barSkin: ClassReference('MySkin');
}
However, none of the code inside MySkin gets executed.
Anyone ever done this ?