2D Toolkit Forum
2D Toolkit => Support => Topic started by: maureli on February 14, 2014, 04:07:11 am
-
I created two UITextInput fields for a username and password and somehow, when the password field is selected, the username field is also being updated. Any idea what is going on and how to fix this? Thanks.
-
What version of tk2d are you using? Can you reproduce this in a simple scene and email support?
-
It says 2.3.0; however, I went to import the latest version and it says none of the files are new. I had picked the new files when this error occurred in an attempt to fix it by updating.
I can put together a simple scene soon. Busy meeting a deadline today.
-
As an update, it appears that it was a lack of having a UIManager in the scene as it stopped happening once I placed one in my scene.
-
Another strange thing is occurring. I am not receiving my SendMessageOnTextChangeMethodName message when I type into the UITextInput field on iOS.
-
Funny, I had the exact same problem yesterday. The OnTextChange message is received fine in the editor, but nothing happens in iOS.
-
Apparently it's because of this problem: http://answers.unity3d.com/questions/464901/inputinputstring-on-ios-empty-1.html
I patched tk2dUITextInput.cs with this code, inserted around line 289:
#if UNITY_IOS && !UNITY_EDITOR
inputStr = keyboard.text;
if(!inputStr.Equals(text)) {
newText = inputStr;
change = true;
}
#endif
Works for me.
Cheers
-
I added that code before the loop around that location and now I get duplicate input for every character typed on iOS.
-
No, you should add it after the loop. Right before
if(change) {}
-
is this patch going to be added in the next release? i updated my version of 2dtk and was bitten by this bug again.
- Paul
-
I've put into 2.5, but I bet as soon as thats released, Unity go and fix that original bug ....
-
Android text input is duplicating all input but on device only, not in the editor. Is there a fix for this?
-
Just tested the latest version - it works fine running on android. What version of tk2d are you testing this on?
-
I am running version 2.4.0. and was running Unity 4.3.
-
The script hasn't changed in a very very long time, and seems to work fine in my tests. Please post a repro case for this so I can try to reproduce this.