[TIMOB-13112] MobileWeb: keyboard is not shown when TextField is programmatically focused
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Won't Fix |
Resolution Date | 2017-06-26T20:10:11.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | MobileWeb |
Labels | n/a |
Reporter | Yaroslav Pidstryhach |
Assignee | Chris Barber |
Created | 2013-03-18T17:26:48.000+0000 |
Updated | 2018-04-04T23:20:16.000+0000 |
Description
*Reproduction steps:*
Create a TextField.
Call the focus() method of the TextField.
(or run the test code below / attached project, and press the Focus button)
*Expected behavior:*
The keyboard is shown.
*Actual behavior:*
The keyboard isn't shown.
*Additional information:*
The keyboard will show if the TextField is focused manually by tapping it.
Worked before version 3.
*Test code:*
var win = Ti.UI.createWindow({
backgroundColor:'#FFFFFF'
}),
tf1 = Titanium.UI.createTextField({
color:'#336699',
height:35,
top:10,
width:250,
}),
l = Titanium.UI.createLabel({
top:60,
width:300,
height:'auto',
color:'#000',
text:'do something like click a button...'
});
win.add(l);
tf1.addEventListener('focus',function(e) {
l.text = 'focus received, val = ' + e.value;
});
tf1.addEventListener('blur',function(e) {
l.text = 'blur received, val = ' + e.value;
});
win.add(tf1);
//
// FOCUS
//
var focusLabel = Titanium.UI.createButton({
top:100,
height:40,
width:200,
title:'Focus'
});
win.add(focusLabel);
focusLabel.addEventListener('click', function() {
tf1.focus();
});
//
// BLUR
//
var blurLabel = Titanium.UI.createButton({
top:150,
height:40,
width:200,
title:'Blur'
});
win.add(blurLabel);
blurLabel.addEventListener('click', function() {
tf1.blur();
});
win.open();
Attachments
File | Date | Size |
---|---|---|
TestKeyboard.zip | 2013-03-18T17:26:48.000+0000 | 1552436 |
Hello, what device(s) are you testing on? Does it work on the browser for you?
Can be reproduced in Android 4 (emulator and actual device) by loading the MobileWeb app in the browser. This bug can also be seen in a compiled Android application (this will be a separate issue though).
I actually do see the same issue with 2.1.4: would you confirm that?
Have also encountered this issue on Titanium SDK 3.2.2.GA. Any workaround for this? On iOS and Anroid, it's working fine.
Marking ticket as "Won't Fix" as MobileWeb has been deprecated.
Closing as will not fix.