codenameone / CodenameOne

Cross-platform framework for building truly native mobile apps with Java or Kotlin. Write Once Run Anywhere support for iOS, Android, Desktop & Web.
https://www.codenameone.com/
Other
1.71k stars 408 forks source link

ios app hangs when AutoCompleteTextField is in scrollable container #1294

Closed codenameone closed 9 years ago

codenameone commented 9 years ago

Original issue 1295 created by codenameone on 2015-01-18T14:05:36.000Z:

What steps will reproduce the problem?

  1. Paste the following code in the start() of a new HelloWorld codenameone project:
    if(current != null)
    {
        current.show();
        return;
    }  

    Form hi = new Form();
    hi.setLayout(new BorderLayout());
    Container c = new Container(new FlowLayout());
    c.setScrollable(true);

    String[] s = {"Java", "CN1", "Codename One", "Form", "Container", "Theme", "BorderLayout", "FlowLayout"};
    AutoCompleteTextField af = new AutoCompleteTextField(s);
    c.addComponent(af);

    hi.addComponent(BorderLayout.CENTER, c);
    hi.show();
  1. Make a build for ios and install/run the program. Add random characters to the autocompletetextfield. Also, use the 'backspace' button. You can see the cursor is at the start of the textfield and it's 'blinking'.
  2. The app will hang after some time.

What is the expected output? What do you see instead? Expected output is a smooth textfield.

What version of the product are you using? On what operating system? iOS 7. On Android, this is working well, as well as in the simulator.

Please provide any additional information below. The hanging app is caused by a scrollable container. When the AutoCompleteTextField is not in a scrollable container, everything is OK. On Android, this is working OK, but on iOS (ios 7, didn't test on another version), it's not. This is seen on the new VM as well on the old VM. When typing a word that's already in the list, the autocompletetextfield is working OK. When using a model instead of an Array, the same problem occurs.

codenameone commented 9 years ago

Comment #1 originally posted by codenameone on 2015-02-01T06:58:16.000Z:

We recently made a fix for a regression introduced in text input on iOS. Can you check that it resolved this issue? If not we'll reopen it.

maaikez commented 9 years ago

I finally had time to go on with the app development. I hoped everything was ok now, but the app still hangs with above code :(.