You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by ha...@apache.org on 2021/05/08 21:31:27 UTC

[royale-asjs] branch develop updated: Update TextInput.as

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

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


The following commit(s) were added to refs/heads/develop by this push:
     new c1ac903  Update TextInput.as
     new 44d25c7  Merge pull request #1060 from jmegonzalez/patch-1
c1ac903 is described below

commit c1ac90308f78fa739bf6883b9aa1afbc16e039bd
Author: jmegonzalez <46...@users.noreply.github.com>
AuthorDate: Fri Jan 22 17:34:20 2021 +0100

    Update TextInput.as
    
    When value is "true" the readOnly attribute is set to "true", instead of "false".
---
 .../projects/MXRoyale/src/main/royale/mx/controls/TextInput.as     | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/TextInput.as b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/TextInput.as
index 40c0063..86825f3 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/TextInput.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/TextInput.as
@@ -659,12 +659,7 @@ public class TextInput extends UIComponent implements ITextInput
         _editable = value;
 	COMPILE::JS
 	{
-		if(value == false) {
-			(element as HTMLInputElement).readOnly = true;
-		}
-		else {
-			 (element as HTMLInputElement).readOnly = value;
-		}
+		(element as HTMLInputElement).readOnly = !value;
 	}
 	
      /*   if (value == _editable)