Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-9169] iOS: Text Area: The focus on text area does not happen through focus method call after toggling the enabled state of text area

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionCannot Reproduce
Resolution Date2013-04-01T11:37:48.000+0000
Affected Version/sRelease 2.0.2
Fix Version/sRelease 3.0.2
ComponentsiOS
Labelsapi, qe-ios050912
ReporterSatyam Sekhri
AssigneeShameer Jan
Created2012-05-18T02:05:14.000+0000
Updated2017-03-21T22:04:37.000+0000

Description

The focus on text area does not happen and the keyboard is not shown when focus for the text area is called after disabling and then enabling (i.e. toggling the editable state) the text area. Steps: 1. Create and open the app 2. click on text area or Focus button 3. Click on Toggle "editable" button 4. Click on Focus 5. Again Click on Toggle "editable" button 6. Now click on Focus Expected Result: After Step2: Text area is enabled and keyboard shows After Step4: Focus on text area does not happen and keyboard does not show up After Step6: Focus on text area happen and keyboard show up Actual Result: After Step6: The focus on the text area does not happen on click of Focus button. However, if the user taps on text area and gains focus on it, the focus button starts behaving correctly. App.js
var win = Ti.UI.createWindow({
    backgroundColor : 'black'
});
         
var ta1 = Titanium.UI.createTextArea({
	editable: true,
	height:70,
	width:300,
	top:60,	
});
win.add(ta1);

var b1 = Titanium.UI.createButton({
	title:'Focus',
	height:40,
	width:200,
	top:140
});
win.add(b1);
b1.addEventListener('click', function()
{
	ta1.focus();
});

var b5 = Titanium.UI.createButton({
	title:'Toggle "editable"',
	top:340,
	height:40,
	width:200
});
win.add(b5);
b5.addEventListener('click',function(){
	ta1.editable = !ta1.editable;
});
win.open();

Comments

  1. Shameer Jan 2013-04-01

    Issue does not reproduces Tested with Titanium Studio, build: 3.0.1.201212181159 Titanium SDK version: 3.1.0 Titanium SDK version: 3.0.2 iOS iPad Simulator: iOS SDK version: 5.1
  2. jithinpv 2014-01-24

    This still happens in android Tested with Titanium studio 3.2.0 Titanium sdk 3.2.0
  3. Lee Morris 2017-03-21

    Closing ticket as the issue cannot be reproduced and due to the above comments.

JSON Source