Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-16834

Setting TextInput text attribute in enter handler does not change displayed text

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • Adobe Flex SDK 3.2 (Release)
    • mx: TextInput
    • None
    • Affected OS(s): Mac
      Affected OS(s): Mac OS 10.5
      Browser: Other (specify version)
      Language Found: English

    Description

      Steps to reproduce:
      1. Make sure to be using SDK 3.2 and FlashPlayer 10
      2. Call a method that changes a TextInput's text attribute.
      3. Make the same method call using a button to verify text attribute can be modified.

      The source below works as intended in SDK 3.0, but fails everytime in SDK 3.2. I tested this in FireFox 3.

      Bug does not exist in AIR applications.

      (See source below)

      Actual Results:
      Debugging shows that the text attribute is changed, but the change in text is not reflected in the TextInput.

      Expected Results:
      Setting the text attribute should be reflected in the text shown in the TextInput

      Workaround (if any):
      Call validateNow()

      Source:

      <?xml version="1.0" encoding="utf-8"?>
      <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" horizontalAlign="center" verticalAlign="middle">
      <mx:Script>
      <![CDATA[
      private function ClearMyTI():void

      { this.myTI.text = null; }

      private function onKeyUp():void

      { this.myTC.text = this.myTI.text; }

      ]]
      >
      </mx:Script>
      <mx:Text text="

      {this.myTI.text}

      "/>
      <mx:Text id="myTC"/>
      <mx:TextInput id="myTI" enter="this.ClearMyTI()" keyUp="this.onKeyUp()"/>
      <mx:Button label="Clear Text Input" click="this.ClearMyTI()"/>
      </mx:Application>

      Attachments

        Activity

          People

            adobejira Adobe JIRA
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: