Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-11903

Android: TextField in a TableViewRow loses focus mysteriously and can't be focused with .focus()

    Details

      Description

      Problem

      TextField (on a TableViewRow) loses focus mysteriously after being focused with a click. The keyboard pops up correctly, but then focus is removed from the TextField (blur does fire), even though the keyboard remains. Typing on the keyboard does not affect the TextField. A second click of the TextField focuses it and the keyboard works.

      Also, the same TextField can't be focused with .focus()...the call to .focus() is simply ignored.

      Testcase

      app.js

      var win1 = Ti.UI.createWindow({  
          backgroundColor:'black'
      });
       
      win1.addEventListener('open',MainWinLoad);
        function MainWinLoad()
        {
        Ti.API.info('--> trying to focus the text field');
          TheTextField.focus();
        }
       
      var TheListBox=Ti.UI.createTableView({width:'auto'});
      var BIRow=Ti.UI.createTableViewRow({color:'white',
                                          title:'No background image',
                                          height:120});
      var TheTextField=Ti.UI.createTextField({keyboardType:Ti.UI.KEYBOARD_DEFAULT,
                                                returnKeyType:Ti.UI.RETURNKEY_DEFAULT,
                                                autocorrect:false,
                                                width:100,
                                                top:55,
                                                left:2
                                               });
      BIRow.add(TheTextField);
       
      TheListBox.appendRow(BIRow);
       
      win1.open();
      win1.add(TheListBox);
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                dsefton Daniel Sefton
                Reporter:
                bitshftr Shawn Lipscomb
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

                  • Titanium SDK/CLI <> Titanium Mobile
                    Synced with:
                    TIMOB-15051
                    Sync status:
                    ERROR
                    Last received:
                    Last sent:

                    Git Integration