 
 package spark.components
 {
+import mx.core.ClassFactory;
 import mx.core.IFactory;
 import mx.core.mx_internal;
-import mx.events.FlexEvent;
 import mx.utils.BitFlagUtil;
 
 import spark.components.supportClasses.ButtonBase;
 import spark.components.supportClasses.DropDownController;
+import spark.core.ContainerDestructionPolicy;
 import spark.events.DropDownEvent;
 import spark.events.PopUpEvent;
+import spark.layouts.supportClasses.LayoutBase;
 
 use namespace mx_internal;
 

//  Styles
//--------------------------------------

include "../styles/metadata/StyleableTextFieldTextStyles.as"

/**
 *  Class or instance to use as the icon for the openButton skin part.
 *  The icon can render from various graphical sources, including the following:  
 *  <ul>
 *   <li>A Bitmap or BitmapData instance.</li>
 *   <li>A class representing a subclass of DisplayObject. The BitmapFill 
 *       instantiates the class and creates a bitmap rendering of it.</li>
 *   <li>An instance of a DisplayObject. The BitmapFill copies it into a 
 *       Bitmap for filling.</li>
 *   <li>The name of an external image file. </li>
 *  </ul>
 * 
 *  @default null
 */
[Style(name="icon", type="Object", inherit="no")]

//--------------------------------------
//  Events

    //
    //--------------------------------------------------------------------------
    
    override protected function attachSkin():void
    {
        super.attachSkin();
        
        // create dropDown if it was not found in the skin
        if (!dropDown && !("dropDown" in skin))
            dropDown = new ClassFactory(Callout);
    }
    
    /**
     *  @private
     */
