home *** CD-ROM | disk | FTP | other *** search
/ Computer Active 2010 August / CA08.iso / Multimedija / shufflr.air / ShufflrClient.swf / scripts / mx / core / UITextField.as < prev    next >
Encoding:
Text File  |  2010-06-23  |  26.5 KB  |  962 lines

  1. package mx.core
  2. {
  3.    import flash.display.DisplayObject;
  4.    import flash.display.DisplayObjectContainer;
  5.    import flash.display.Sprite;
  6.    import flash.events.Event;
  7.    import flash.text.TextFormat;
  8.    import flash.text.TextLineMetrics;
  9.    import flash.utils.getQualifiedClassName;
  10.    import mx.automation.IAutomationObject;
  11.    import mx.managers.ISystemManager;
  12.    import mx.managers.IToolTipManagerClient;
  13.    import mx.managers.SystemManager;
  14.    import mx.managers.ToolTipManager;
  15.    import mx.resources.IResourceManager;
  16.    import mx.resources.ResourceManager;
  17.    import mx.styles.ISimpleStyleClient;
  18.    import mx.styles.IStyleClient;
  19.    import mx.styles.StyleManager;
  20.    import mx.styles.StyleProtoChain;
  21.    import mx.utils.StringUtil;
  22.    
  23.    use namespace mx_internal;
  24.    
  25.    public class UITextField extends FlexTextField implements IAutomationObject, IIMESupport, IFlexModule, IInvalidating, ISimpleStyleClient, IToolTipManagerClient, IUITextField
  26.    {
  27.       private static var truncationIndicatorResource:String;
  28.       
  29.       private static var _embeddedFontRegistry:IEmbeddedFontRegistry;
  30.       
  31.       mx_internal static const VERSION:String = "3.5.0.12683";
  32.       
  33.       mx_internal static const TEXT_WIDTH_PADDING:int = 5;
  34.       
  35.       mx_internal static const TEXT_HEIGHT_PADDING:int = 4;
  36.       
  37.       mx_internal static var debuggingBorders:Boolean = false;
  38.       
  39.       private var _enabled:Boolean = true;
  40.       
  41.       private var untruncatedText:String;
  42.       
  43.       private var cachedEmbeddedFont:EmbeddedFont = null;
  44.       
  45.       private var cachedTextFormat:TextFormat;
  46.       
  47.       private var _automationDelegate:IAutomationObject;
  48.       
  49.       private var _automationName:String;
  50.       
  51.       private var _styleName:Object;
  52.       
  53.       private var _document:Object;
  54.       
  55.       mx_internal var _toolTip:String;
  56.       
  57.       private var _nestLevel:int = 0;
  58.       
  59.       private var _explicitHeight:Number;
  60.       
  61.       private var _moduleFactory:IFlexModuleFactory;
  62.       
  63.       private var _initialized:Boolean = false;
  64.       
  65.       private var _nonInheritingStyles:Object = UIComponent.mx_internal::STYLE_UNINITIALIZED;
  66.       
  67.       private var _inheritingStyles:Object = UIComponent.mx_internal::STYLE_UNINITIALIZED;
  68.       
  69.       private var _includeInLayout:Boolean = true;
  70.       
  71.       private var invalidateDisplayListFlag:Boolean = true;
  72.       
  73.       mx_internal var explicitColor:uint = 4294967295;
  74.       
  75.       private var _processedDescriptors:Boolean = true;
  76.       
  77.       private var _updateCompletePendingFlag:Boolean = false;
  78.       
  79.       private var explicitHTMLText:String = null;
  80.       
  81.       mx_internal var _parent:DisplayObjectContainer;
  82.       
  83.       private var _imeMode:String = null;
  84.       
  85.       private var resourceManager:IResourceManager = ResourceManager.getInstance();
  86.       
  87.       mx_internal var styleChangedFlag:Boolean = true;
  88.       
  89.       private var _ignorePadding:Boolean = true;
  90.       
  91.       private var _owner:DisplayObjectContainer;
  92.       
  93.       private var _explicitWidth:Number;
  94.       
  95.       public function UITextField()
  96.       {
  97.          super();
  98.          super.text = "";
  99.          focusRect = false;
  100.          selectable = false;
  101.          tabEnabled = false;
  102.          if(mx_internal::debuggingBorders)
  103.          {
  104.             border = true;
  105.          }
  106.          if(!truncationIndicatorResource)
  107.          {
  108.             truncationIndicatorResource = resourceManager.getString("core","truncationIndicator");
  109.          }
  110.          addEventListener(Event.CHANGE,changeHandler);
  111.          addEventListener("textFieldStyleChange",textFieldStyleChangeHandler);
  112.          resourceManager.addEventListener(Event.CHANGE,resourceManager_changeHandler,false,0,true);
  113.       }
  114.       
  115.       private static function get embeddedFontRegistry() : IEmbeddedFontRegistry
  116.       {
  117.          if(!_embeddedFontRegistry)
  118.          {
  119.             _embeddedFontRegistry = IEmbeddedFontRegistry(Singleton.getInstance("mx.core::IEmbeddedFontRegistry"));
  120.          }
  121.          return _embeddedFontRegistry;
  122.       }
  123.       
  124.       public function set imeMode(param1:String) : void
  125.       {
  126.          _imeMode = param1;
  127.       }
  128.       
  129.       public function get nestLevel() : int
  130.       {
  131.          return _nestLevel;
  132.       }
  133.       
  134.       private function textFieldStyleChangeHandler(param1:Event) : void
  135.       {
  136.          if(explicitHTMLText != null)
  137.          {
  138.             super.htmlText = explicitHTMLText;
  139.          }
  140.       }
  141.       
  142.       public function truncateToFit(param1:String = null) : Boolean
  143.       {
  144.          var _loc4_:String = null;
  145.          if(!param1)
  146.          {
  147.             param1 = truncationIndicatorResource;
  148.          }
  149.          validateNow();
  150.          var _loc2_:String = super.text;
  151.          untruncatedText = _loc2_;
  152.          var _loc3_:Number = width;
  153.          if(_loc2_ != "" && textWidth + mx_internal::TEXT_WIDTH_PADDING > _loc3_ + 1e-14)
  154.          {
  155.             _loc4_ = super.text = _loc2_;
  156.             _loc2_.slice(0,Math.floor(_loc3_ / (textWidth + mx_internal::TEXT_WIDTH_PADDING) * _loc2_.length));
  157.             while(_loc4_.length > 1 && textWidth + mx_internal::TEXT_WIDTH_PADDING > _loc3_)
  158.             {
  159.                _loc4_ = _loc4_.slice(0,-1);
  160.                super.text = _loc4_ + param1;
  161.             }
  162.             return true;
  163.          }
  164.          return false;
  165.       }
  166.       
  167.       public function set nestLevel(param1:int) : void
  168.       {
  169.          if(param1 > 1 && _nestLevel != param1)
  170.          {
  171.             _nestLevel = param1;
  172.             StyleProtoChain.initTextField(this);
  173.             mx_internal::styleChangedFlag = true;
  174.             validateNow();
  175.          }
  176.       }
  177.       
  178.       public function get minHeight() : Number
  179.       {
  180.          return 0;
  181.       }
  182.       
  183.       public function getExplicitOrMeasuredHeight() : Number
  184.       {
  185.          return !isNaN(explicitHeight) ? explicitHeight : measuredHeight;
  186.       }
  187.       
  188.       public function getStyle(param1:String) : *
  189.       {
  190.          if(StyleManager.mx_internal::inheritingStyles[param1])
  191.          {
  192.             return !!inheritingStyles ? inheritingStyles[param1] : IStyleClient(parent).getStyle(param1);
  193.          }
  194.          return !!nonInheritingStyles ? nonInheritingStyles[param1] : IStyleClient(parent).getStyle(param1);
  195.       }
  196.       
  197.       public function get className() : String
  198.       {
  199.          var _loc1_:String = getQualifiedClassName(this);
  200.          var _loc2_:int = int(_loc1_.indexOf("::"));
  201.          if(_loc2_ != -1)
  202.          {
  203.             _loc1_ = _loc1_.substr(_loc2_ + 2);
  204.          }
  205.          return _loc1_;
  206.       }
  207.       
  208.       public function setColor(param1:uint) : void
  209.       {
  210.          mx_internal::explicitColor = param1;
  211.          mx_internal::styleChangedFlag = true;
  212.          invalidateDisplayListFlag = true;
  213.          validateNow();
  214.       }
  215.       
  216.       override public function replaceText(param1:int, param2:int, param3:String) : void
  217.       {
  218.          super.replaceText(param1,param2,param3);
  219.          dispatchEvent(new Event("textReplace"));
  220.       }
  221.       
  222.       private function creatingSystemManager() : ISystemManager
  223.       {
  224.          return moduleFactory != null && moduleFactory is ISystemManager ? ISystemManager(moduleFactory) : systemManager;
  225.       }
  226.       
  227.       public function set document(param1:Object) : void
  228.       {
  229.          _document = param1;
  230.       }
  231.       
  232.       public function get automationName() : String
  233.       {
  234.          if(_automationName)
  235.          {
  236.             return _automationName;
  237.          }
  238.          if(automationDelegate)
  239.          {
  240.             return automationDelegate.automationName;
  241.          }
  242.          return "";
  243.       }
  244.       
  245.       public function get explicitMinHeight() : Number
  246.       {
  247.          return NaN;
  248.       }
  249.       
  250.       public function get focusPane() : Sprite
  251.       {
  252.          return null;
  253.       }
  254.       
  255.       public function getTextStyles() : TextFormat
  256.       {
  257.          var _loc1_:TextFormat = new TextFormat();
  258.          _loc1_.align = getStyle("textAlign");
  259.          _loc1_.bold = getStyle("fontWeight") == "bold";
  260.          if(enabled)
  261.          {
  262.             if(mx_internal::explicitColor == StyleManager.NOT_A_COLOR)
  263.             {
  264.                _loc1_.color = getStyle("color");
  265.             }
  266.             else
  267.             {
  268.                _loc1_.color = mx_internal::explicitColor;
  269.             }
  270.          }
  271.          else
  272.          {
  273.             _loc1_.color = getStyle("disabledColor");
  274.          }
  275.          _loc1_.font = StringUtil.trimArrayElements(getStyle("fontFamily"),",");
  276.          _loc1_.indent = getStyle("textIndent");
  277.          _loc1_.italic = getStyle("fontStyle") == "italic";
  278.          _loc1_.kerning = getStyle("kerning");
  279.          _loc1_.leading = getStyle("leading");
  280.          _loc1_.leftMargin = ignorePadding ? 0 : getStyle("paddingLeft");
  281.          _loc1_.letterSpacing = getStyle("letterSpacing");
  282.          _loc1_.rightMargin = ignorePadding ? 0 : getStyle("paddingRight");
  283.          _loc1_.size = getStyle("fontSize");
  284.          _loc1_.underline = getStyle("textDecoration") == "underline";
  285.          cachedTextFormat = _loc1_;
  286.          return _loc1_;
  287.       }
  288.       
  289.       override public function set text(param1:String) : void
  290.       {
  291.          if(!param1)
  292.          {
  293.             param1 = "";
  294.          }
  295.          if(!isHTML && super.text == param1)
  296.          {
  297.             return;
  298.          }
  299.          super.text = param1;
  300.          explicitHTMLText = null;
  301.          if(invalidateDisplayListFlag)
  302.          {
  303.             validateNow();
  304.          }
  305.       }
  306.       
  307.       public function getExplicitOrMeasuredWidth() : Number
  308.       {
  309.          return !isNaN(explicitWidth) ? explicitWidth : measuredWidth;
  310.       }
  311.       
  312.       public function get showInAutomationHierarchy() : Boolean
  313.       {
  314.          return true;
  315.       }
  316.       
  317.       public function set automationName(param1:String) : void
  318.       {
  319.          _automationName = param1;
  320.       }
  321.       
  322.       public function get systemManager() : ISystemManager
  323.       {
  324.          var _loc2_:IUIComponent = null;
  325.          var _loc1_:DisplayObject = parent;
  326.          while(_loc1_)
  327.          {
  328.             _loc2_ = _loc1_ as IUIComponent;
  329.             if(_loc2_)
  330.             {
  331.                return _loc2_.systemManager;
  332.             }
  333.             _loc1_ = _loc1_.parent;
  334.          }
  335.          return null;
  336.       }
  337.       
  338.       public function setStyle(param1:String, param2:*) : void
  339.       {
  340.       }
  341.       
  342.       public function get percentWidth() : Number
  343.       {
  344.          return NaN;
  345.       }
  346.       
  347.       public function get explicitHeight() : Number
  348.       {
  349.          return _explicitHeight;
  350.       }
  351.       
  352.       public function get baselinePosition() : Number
  353.       {
  354.          var _loc1_:TextLineMetrics = null;
  355.          if(FlexVersion.compatibilityVersion < FlexVersion.VERSION_3_0)
  356.          {
  357.             _loc1_ = getLineMetrics(0);
  358.             return height - 4 - _loc1_.descent;
  359.          }
  360.          if(!parent)
  361.          {
  362.             return NaN;
  363.          }
  364.          var _loc2_:* = text == "";
  365.          if(_loc2_)
  366.          {
  367.             super.text = "Wj";
  368.          }
  369.          _loc1_ = getLineMetrics(0);
  370.          if(_loc2_)
  371.          {
  372.             super.text = "";
  373.          }
  374.          return 2 + _loc1_.ascent;
  375.       }
  376.       
  377.       public function set enabled(param1:Boolean) : void
  378.       {
  379.          mouseEnabled = param1;
  380.          _enabled = param1;
  381.          styleChanged("color");
  382.       }
  383.       
  384.       public function get minWidth() : Number
  385.       {
  386.          return 0;
  387.       }
  388.       
  389.       public function get automationValue() : Array
  390.       {
  391.          if(automationDelegate)
  392.          {
  393.             return automationDelegate.automationValue;
  394.          }
  395.          return [""];
  396.       }
  397.       
  398.       public function get tweeningProperties() : Array
  399.       {
  400.          return null;
  401.       }
  402.       
  403.       public function get measuredWidth() : Number
  404.       {
  405.          validateNow();
  406.          if(!stage)
  407.          {
  408.             return textWidth + mx_internal::TEXT_WIDTH_PADDING;
  409.          }
  410.          return textWidth * transform.concatenatedMatrix.d + mx_internal::TEXT_WIDTH_PADDING;
  411.       }
  412.       
  413.       public function set tweeningProperties(param1:Array) : void
  414.       {
  415.       }
  416.       
  417.       public function createAutomationIDPart(param1:IAutomationObject) : Object
  418.       {
  419.          return null;
  420.       }
  421.       
  422.       override public function get parent() : DisplayObjectContainer
  423.       {
  424.          return !!mx_internal::_parent ? mx_internal::_parent : super.parent;
  425.       }
  426.       
  427.       public function set updateCompletePendingFlag(param1:Boolean) : void
  428.       {
  429.          _updateCompletePendingFlag = param1;
  430.       }
  431.       
  432.       public function setActualSize(param1:Number, param2:Number) : void
  433.       {
  434.          if(width != param1)
  435.          {
  436.             width = param1;
  437.          }
  438.          if(height != param2)
  439.          {
  440.             height = param2;
  441.          }
  442.       }
  443.       
  444.       public function get numAutomationChildren() : int
  445.       {
  446.          return 0;
  447.       }
  448.       
  449.       public function set focusPane(param1:Sprite) : void
  450.       {
  451.       }
  452.       
  453.       public function getAutomationChildAt(param1:int) : IAutomationObject
  454.       {
  455.          return null;
  456.       }
  457.       
  458.       public function get inheritingStyles() : Object
  459.       {
  460.          return _inheritingStyles;
  461.       }
  462.       
  463.       public function get owner() : DisplayObjectContainer
  464.       {
  465.          return !!_owner ? _owner : parent;
  466.       }
  467.       
  468.       public function parentChanged(param1:DisplayObjectContainer) : void
  469.       {
  470.          if(!param1)
  471.          {
  472.             mx_internal::_parent = null;
  473.             _nestLevel = 0;
  474.          }
  475.          else if(param1 is IStyleClient)
  476.          {
  477.             mx_internal::_parent = param1;
  478.          }
  479.          else if(param1 is SystemManager)
  480.          {
  481.             mx_internal::_parent = param1;
  482.          }
  483.          else
  484.          {
  485.             mx_internal::_parent = param1.parent;
  486.          }
  487.       }
  488.       
  489.       public function get processedDescriptors() : Boolean
  490.       {
  491.          return _processedDescriptors;
  492.       }
  493.       
  494.       public function get maxWidth() : Number
  495.       {
  496.          return UIComponent.DEFAULT_MAX_WIDTH;
  497.       }
  498.       
  499.       private function getEmbeddedFont(param1:String, param2:Boolean, param3:Boolean) : EmbeddedFont
  500.       {
  501.          if(cachedEmbeddedFont)
  502.          {
  503.             if(cachedEmbeddedFont.fontName == param1 && cachedEmbeddedFont.fontStyle == EmbeddedFontRegistry.getFontStyle(param2,param3))
  504.             {
  505.                return cachedEmbeddedFont;
  506.             }
  507.          }
  508.          cachedEmbeddedFont = new EmbeddedFont(param1,param2,param3);
  509.          return cachedEmbeddedFont;
  510.       }
  511.       
  512.       public function get initialized() : Boolean
  513.       {
  514.          return _initialized;
  515.       }
  516.       
  517.       public function invalidateDisplayList() : void
  518.       {
  519.          invalidateDisplayListFlag = true;
  520.       }
  521.       
  522.       public function invalidateProperties() : void
  523.       {
  524.       }
  525.       
  526.       override public function insertXMLText(param1:int, param2:int, param3:String, param4:Boolean = false) : void
  527.       {
  528.          super.insertXMLText(param1,param2,param3,param4);
  529.          dispatchEvent(new Event("textInsert"));
  530.       }
  531.       
  532.       public function set includeInLayout(param1:Boolean) : void
  533.       {
  534.          var _loc2_:IInvalidating = null;
  535.          if(_includeInLayout != param1)
  536.          {
  537.             _includeInLayout = param1;
  538.             _loc2_ = parent as IInvalidating;
  539.             if(_loc2_)
  540.             {
  541.                _loc2_.invalidateSize();
  542.                _loc2_.invalidateDisplayList();
  543.             }
  544.          }
  545.       }
  546.       
  547.       override public function set htmlText(param1:String) : void
  548.       {
  549.          if(!param1)
  550.          {
  551.             param1 = "";
  552.          }
  553.          if(isHTML && super.htmlText == param1)
  554.          {
  555.             return;
  556.          }
  557.          if(Boolean(cachedTextFormat) && styleSheet == null)
  558.          {
  559.             defaultTextFormat = cachedTextFormat;
  560.          }
  561.          super.htmlText = param1;
  562.          explicitHTMLText = param1;
  563.          if(invalidateDisplayListFlag)
  564.          {
  565.             validateNow();
  566.          }
  567.       }
  568.       
  569.       public function set showInAutomationHierarchy(param1:Boolean) : void
  570.       {
  571.       }
  572.       
  573.       private function resourceManager_changeHandler(param1:Event) : void
  574.       {
  575.          truncationIndicatorResource = resourceManager.getString("core","truncationIndicator");
  576.          if(untruncatedText != null)
  577.          {
  578.             super.text = untruncatedText;
  579.             truncateToFit();
  580.          }
  581.       }
  582.       
  583.       public function set measuredMinWidth(param1:Number) : void
  584.       {
  585.       }
  586.       
  587.       public function set explicitHeight(param1:Number) : void
  588.       {
  589.          _explicitHeight = param1;
  590.       }
  591.       
  592.       public function get explicitMinWidth() : Number
  593.       {
  594.          return NaN;
  595.       }
  596.       
  597.       public function set percentWidth(param1:Number) : void
  598.       {
  599.       }
  600.       
  601.       public function get imeMode() : String
  602.       {
  603.          return _imeMode;
  604.       }
  605.       
  606.       public function get moduleFactory() : IFlexModuleFactory
  607.       {
  608.          return _moduleFactory;
  609.       }
  610.       
  611.       public function set systemManager(param1:ISystemManager) : void
  612.       {
  613.       }
  614.       
  615.       public function get explicitMaxWidth() : Number
  616.       {
  617.          return NaN;
  618.       }
  619.       
  620.       public function get document() : Object
  621.       {
  622.          return _document;
  623.       }
  624.       
  625.       public function get updateCompletePendingFlag() : Boolean
  626.       {
  627.          return _updateCompletePendingFlag;
  628.       }
  629.       
  630.       public function replayAutomatableEvent(param1:Event) : Boolean
  631.       {
  632.          if(automationDelegate)
  633.          {
  634.             return automationDelegate.replayAutomatableEvent(param1);
  635.          }
  636.          return false;
  637.       }
  638.       
  639.       public function get enabled() : Boolean
  640.       {
  641.          return _enabled;
  642.       }
  643.       
  644.       public function set owner(param1:DisplayObjectContainer) : void
  645.       {
  646.          _owner = param1;
  647.       }
  648.       
  649.       public function get automationTabularData() : Object
  650.       {
  651.          return null;
  652.       }
  653.       
  654.       public function set nonInheritingStyles(param1:Object) : void
  655.       {
  656.          _nonInheritingStyles = param1;
  657.       }
  658.       
  659.       public function get includeInLayout() : Boolean
  660.       {
  661.          return _includeInLayout;
  662.       }
  663.       
  664.       public function get measuredMinWidth() : Number
  665.       {
  666.          return 0;
  667.       }
  668.       
  669.       public function set isPopUp(param1:Boolean) : void
  670.       {
  671.       }
  672.       
  673.       public function set automationDelegate(param1:Object) : void
  674.       {
  675.          _automationDelegate = param1 as IAutomationObject;
  676.       }
  677.       
  678.       public function get measuredHeight() : Number
  679.       {
  680.          validateNow();
  681.          if(!stage)
  682.          {
  683.             return textHeight + mx_internal::TEXT_HEIGHT_PADDING;
  684.          }
  685.          return textHeight * transform.concatenatedMatrix.a + mx_internal::TEXT_HEIGHT_PADDING;
  686.       }
  687.       
  688.       public function set processedDescriptors(param1:Boolean) : void
  689.       {
  690.          _processedDescriptors = param1;
  691.       }
  692.       
  693.       public function setFocus() : void
  694.       {
  695.          systemManager.stage.focus = this;
  696.       }
  697.       
  698.       public function initialize() : void
  699.       {
  700.       }
  701.       
  702.       public function set percentHeight(param1:Number) : void
  703.       {
  704.       }
  705.       
  706.       public function resolveAutomationIDPart(param1:Object) : Array
  707.       {
  708.          return [];
  709.       }
  710.       
  711.       public function set inheritingStyles(param1:Object) : void
  712.       {
  713.          _inheritingStyles = param1;
  714.       }
  715.       
  716.       public function getUITextFormat() : UITextFormat
  717.       {
  718.          validateNow();
  719.          var _loc1_:UITextFormat = new UITextFormat(creatingSystemManager());
  720.          _loc1_.moduleFactory = moduleFactory;
  721.          _loc1_.mx_internal::copyFrom(getTextFormat());
  722.          _loc1_.antiAliasType = antiAliasType;
  723.          _loc1_.gridFitType = gridFitType;
  724.          _loc1_.sharpness = sharpness;
  725.          _loc1_.thickness = thickness;
  726.          return _loc1_;
  727.       }
  728.       
  729.       private function changeHandler(param1:Event) : void
  730.       {
  731.          explicitHTMLText = null;
  732.       }
  733.       
  734.       public function set initialized(param1:Boolean) : void
  735.       {
  736.          _initialized = param1;
  737.       }
  738.       
  739.       public function get nonZeroTextHeight() : Number
  740.       {
  741.          var _loc1_:Number = NaN;
  742.          if(super.text == "")
  743.          {
  744.             super.text = "Wj";
  745.             _loc1_ = textHeight;
  746.             super.text = "";
  747.             return _loc1_;
  748.          }
  749.          return textHeight;
  750.       }
  751.       
  752.       public function owns(param1:DisplayObject) : Boolean
  753.       {
  754.          return param1 == this;
  755.       }
  756.       
  757.       override public function setTextFormat(param1:TextFormat, param2:int = -1, param3:int = -1) : void
  758.       {
  759.          if(styleSheet)
  760.          {
  761.             return;
  762.          }
  763.          super.setTextFormat(param1,param2,param3);
  764.          dispatchEvent(new Event("textFormatChange"));
  765.       }
  766.       
  767.       public function get nonInheritingStyles() : Object
  768.       {
  769.          return _nonInheritingStyles;
  770.       }
  771.       
  772.       public function setVisible(param1:Boolean, param2:Boolean = false) : void
  773.       {
  774.          this.visible = param1;
  775.       }
  776.       
  777.       public function get maxHeight() : Number
  778.       {
  779.          return UIComponent.DEFAULT_MAX_HEIGHT;
  780.       }
  781.       
  782.       public function get automationDelegate() : Object
  783.       {
  784.          return _automationDelegate;
  785.       }
  786.       
  787.       public function get isPopUp() : Boolean
  788.       {
  789.          return false;
  790.       }
  791.       
  792.       public function set ignorePadding(param1:Boolean) : void
  793.       {
  794.          _ignorePadding = param1;
  795.          styleChanged(null);
  796.       }
  797.       
  798.       public function set styleName(param1:Object) : void
  799.       {
  800.          if(_styleName === param1)
  801.          {
  802.             return;
  803.          }
  804.          _styleName = param1;
  805.          if(parent)
  806.          {
  807.             StyleProtoChain.initTextField(this);
  808.             styleChanged("styleName");
  809.          }
  810.       }
  811.       
  812.       public function styleChanged(param1:String) : void
  813.       {
  814.          mx_internal::styleChangedFlag = true;
  815.          if(!invalidateDisplayListFlag)
  816.          {
  817.             invalidateDisplayListFlag = true;
  818.             if("callLater" in parent)
  819.             {
  820.                Object(parent).callLater(validateNow);
  821.             }
  822.          }
  823.       }
  824.       
  825.       public function get percentHeight() : Number
  826.       {
  827.          return NaN;
  828.       }
  829.       
  830.       private function get isHTML() : Boolean
  831.       {
  832.          return explicitHTMLText != null;
  833.       }
  834.       
  835.       public function get explicitMaxHeight() : Number
  836.       {
  837.          return NaN;
  838.       }
  839.       
  840.       public function get styleName() : Object
  841.       {
  842.          return _styleName;
  843.       }
  844.       
  845.       public function set explicitWidth(param1:Number) : void
  846.       {
  847.          _explicitWidth = param1;
  848.       }
  849.       
  850.       public function validateNow() : void
  851.       {
  852.          var _loc1_:TextFormat = null;
  853.          var _loc2_:EmbeddedFont = null;
  854.          var _loc3_:IFlexModuleFactory = null;
  855.          var _loc4_:ISystemManager = null;
  856.          if(!parent)
  857.          {
  858.             return;
  859.          }
  860.          if(!isNaN(explicitWidth) && super.width != explicitWidth)
  861.          {
  862.             super.width = explicitWidth > 4 ? explicitWidth : 4;
  863.          }
  864.          if(!isNaN(explicitHeight) && super.height != explicitHeight)
  865.          {
  866.             super.height = explicitHeight;
  867.          }
  868.          if(mx_internal::styleChangedFlag)
  869.          {
  870.             _loc1_ = getTextStyles();
  871.             if(_loc1_.font)
  872.             {
  873.                _loc2_ = getEmbeddedFont(_loc1_.font,_loc1_.bold,_loc1_.italic);
  874.                _loc3_ = embeddedFontRegistry.getAssociatedModuleFactory(_loc2_,moduleFactory);
  875.                if(_loc3_ != null)
  876.                {
  877.                   embedFonts = true;
  878.                }
  879.                else
  880.                {
  881.                   _loc4_ = creatingSystemManager();
  882.                   embedFonts = _loc4_ != null && Boolean(_loc4_.isFontFaceEmbedded(_loc1_));
  883.                }
  884.             }
  885.             else
  886.             {
  887.                embedFonts = getStyle("embedFonts");
  888.             }
  889.             if(getStyle("fontAntiAliasType") != undefined)
  890.             {
  891.                antiAliasType = getStyle("fontAntiAliasType");
  892.                gridFitType = getStyle("fontGridFitType");
  893.                sharpness = getStyle("fontSharpness");
  894.                thickness = getStyle("fontThickness");
  895.             }
  896.             if(!styleSheet)
  897.             {
  898.                super.setTextFormat(_loc1_);
  899.                defaultTextFormat = _loc1_;
  900.             }
  901.             dispatchEvent(new Event("textFieldStyleChange"));
  902.          }
  903.          mx_internal::styleChangedFlag = false;
  904.          invalidateDisplayListFlag = false;
  905.       }
  906.       
  907.       public function set toolTip(param1:String) : void
  908.       {
  909.          var _loc2_:String = mx_internal::_toolTip;
  910.          mx_internal::_toolTip = param1;
  911.          ToolTipManager.mx_internal::registerToolTip(this,_loc2_,param1);
  912.       }
  913.       
  914.       public function move(param1:Number, param2:Number) : void
  915.       {
  916.          if(this.x != param1)
  917.          {
  918.             this.x = param1;
  919.          }
  920.          if(this.y != param2)
  921.          {
  922.             this.y = param2;
  923.          }
  924.       }
  925.       
  926.       public function get toolTip() : String
  927.       {
  928.          return mx_internal::_toolTip;
  929.       }
  930.       
  931.       public function get ignorePadding() : Boolean
  932.       {
  933.          return _ignorePadding;
  934.       }
  935.       
  936.       public function get explicitWidth() : Number
  937.       {
  938.          return _explicitWidth;
  939.       }
  940.       
  941.       public function invalidateSize() : void
  942.       {
  943.          invalidateDisplayListFlag = true;
  944.       }
  945.       
  946.       public function set measuredMinHeight(param1:Number) : void
  947.       {
  948.       }
  949.       
  950.       public function get measuredMinHeight() : Number
  951.       {
  952.          return 0;
  953.       }
  954.       
  955.       public function set moduleFactory(param1:IFlexModuleFactory) : void
  956.       {
  957.          _moduleFactory = param1;
  958.       }
  959.    }
  960. }
  961.  
  962.