You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by ah...@apache.org on 2019/12/26 08:30:53 UTC

[royale-asjs] 01/02: fix text in UITextField

This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch adg_grouped
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit 35b8fe9b91f2bc059fe7a82dee7da8e4fe3ae44a
Author: Alex Harui <ah...@apache.org>
AuthorDate: Thu Dec 26 00:29:04 2019 -0800

    fix text in UITextField
---
 .../MXRoyale/src/main/royale/mx/core/UITextField.as        | 14 ++++----------
 1 file changed, 4 insertions(+), 10 deletions(-)

diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/core/UITextField.as b/frameworks/projects/MXRoyale/src/main/royale/mx/core/UITextField.as
index a0e49e6..90068fc 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/core/UITextField.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/core/UITextField.as
@@ -717,10 +717,7 @@ public class UITextField  extends UIComponent implements IUITextField
      //  text
      //----------------------------------
      
-     
-     COMPILE::JS
-     protected var textNode:window.Text;
-     
+          
      COMPILE::JS
      private var _text:String = "";
      
@@ -756,12 +753,9 @@ public class UITextField  extends UIComponent implements IUITextField
              }
              COMPILE::JS
              {
-                 if (textNode)
-                 {
-                     _text = value;
-                     textNode.nodeValue = value;
-                     this.dispatchEvent('textChange');
-                 }
+                 _text = value;
+                 this.element.innerText = value;
+                 this.dispatchEvent('textChange');
              }
              
              invalidateSize();