x


Android 4.0 ( ICS ) Keyboard issue

Hi all,

I'm nearly done with a game for Android, but I'm running into some issues with Unity's text fields and the ICS keyboard, which I have noticed, as have 3 of my testers ( Stock Galaxy Nexus and Nexus S users ).

When the keyboard comes up for the first time, everything works as expected. If you dismiss it using the "Ok" button next to the popped up text entry, it works as expected. If you dismiss it with the "Done" button on the keyboard, the keyboard often does not present itself in other text fields and I can't find a consistent to bring it back up. It sometimes takes a few attempts, but this is definitely reproducible.

I'm not using any custom handling of my text fields:

opponent = GUI.TextField(Helpers.ButtonRect(y), opponent, 60); 

Is there anything I can do to work around this issue? I am planning to release soon, and this is sadly a critical bug.

A beta version is online here so you can see: http://bit.ly/ItCVgu

Thanks, David Goemans

more ▼

asked Apr 09 '12 at 11:08 AM

dgoemans gravatar image

dgoemans
86 6 6 12

This is still an issues in 3.5.2

May 20 '12 at 09:30 AM dgoemans

Have the same problem. Can anyone solve this? Please.

Jun 05 '12 at 02:11 PM sargrass

If you don't want to answer the question, don't post an answer.

I've converted your answers into a comment.

Jun 05 '12 at 02:12 PM Bunny83
(comments are locked)
10|3000 characters needed characters left

2 answers: sort voted first

Bug was fixed in 3.5.6

more ▼

answered Jan 14 at 09:18 PM

dgoemans gravatar image

dgoemans
86 6 6 12

(comments are locked)
10|3000 characters needed characters left

Edit! I've changed the way I've done my workaround, so maybe it'll be more effective.

I keep a reference in one of my classes to an instance of TouchScreenKeyboard:

private TouchScreenKeyboard keyboard = null;

in my Start(), I instanciate a keyboard:

keyboard = new TouchScreenKeyboard("", TouchScreenKeyboardType.Default, true, true, false, false, "");
keyboard.active = false;

then, when I want to ensure my keyboard is re-shown, I do:

keyboard.active = false;
TouchScreenKeyboard.Open("current text from text area", TouchScreenKeyboardType.Default, true, true, false, false, "");

I call that code when the user taps on an area that would be a text area. Something like this (pseudocode)

foreach (textarea t in alltextareas)
    if (Input.GetMouseDown(0) && t.MouseIsOver && t.IsClickable)
        ForceShowKeyboard()

Surely there's a better way, but I imagine it will require Unity to change how they interact with the keyboard API on ICS.

Good luck!

more ▼

answered Jul 11 '12 at 11:13 PM

nitz gravatar image

nitz
16 1 1 3

Thanks! The key to work for my Galaxy Tab 2 7.0 was the second block of code.

Oct 09 '12 at 02:05 AM oriolmanya

It's worth noting that this bug has now been fixed in 3.5.6.

Oct 09 '12 at 07:29 AM dgoemans
(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x2489
x195
x5

asked: Apr 09 '12 at 11:08 AM

Seen: 1420 times

Last Updated: Jan 14 at 09:18 PM