July 8, 2009

Mixin’s in ActionScript 3

Filed under: ActionScript, Flex — Anthony @ 11:48 pm

I was strolling through the UIComponent source code earlier today when i cam across this line of code.

 
 //--------------------------------------------------------------------------
    //
    //  Class mixins
    //
    //--------------------------------------------------------------------------
 
    /**
     *  @private
     *  Placeholder for mixin by UIComponentAccImpl.
     */
mx_internal static var createAccessibilityImplementation:Function;
 

I wasn't entirely sure what a mixin was but after reading up on wikipedia I realized they are exactly what they sound like basically just a mix of code bases. There is a really good post over on the yahoo flash blog about accessibility and the way in which Flex uses the

 
[AccessibilityClass(implementation="mx.accessibility.UIComponentAccImpl")]
 

meta data to mixin the Accessibility code into the UIComponent implementation.

No Comments »

No comments yet.

RSS feed for comments on this post. | TrackBack URI

Leave a comment

XHTML ( You can use these tags): <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> .