1 Reply Latest reply on Jan 16, 2013 11:32 AM by roymeo_

    Locale Input changes on Mac OS X Lion when changing the view state

    st-f Level 1

      On Mac OS X Lion, the following code results of changing the locale input when changing the view state. If you set the input locale to Pynin, then run the application, then click on "go to the test 2", the input locale changes back to english. This is obviously not the correct behavior (the input locale should stay the same as defined on the computer).

       

      <?xml version="1.0" encoding="utf-8"?>

      <s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009"

                             xmlns:s="library://ns.adobe.com/flex/spark"

                             xmlns:mx="library://ns.adobe.com/flex/mx">   

          <fx:Script>

              <![CDATA[

                  protected function gototest2(event:MouseEvent):void

                  {

                      this.currentState = "test2";

                  }

       

                  protected function gototest(event:MouseEvent):void

                  {

                      this.currentState = "test";

                  }

       

              ]]>

          </fx:Script>

          <s:states>

              <s:State name="test" />

              <s:State name="test2" />

          </s:states>

          <s:Button label="go to test" includeIn="test2" click="gototest(event)" />

          <s:Button label="go to test2" includeIn="test" click="gototest2(event)" />

          <s:TextInput includeIn="test2" />

      </s:WindowedApplication>