Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-8765] Android: TextField selection position gets reset when TableView resizes.

GitHub Issuen/a
TypeBug
PriorityLow
StatusClosed
ResolutionCannot Reproduce
Resolution Date2017-06-27T18:33:46.000+0000
Affected Version/sRelease 2.1.0
Fix Version/sn/a
ComponentsAndroid
Labelsapi
ReporterJosh Roesslein
AssigneeEric Merriman
Created2012-04-17T12:12:16.000+0000
Updated2017-06-27T18:33:46.000+0000

Description

When a TextField is used inside a TableView, its selection position (cursor) gets reset when a resize of the TableView occurs (ex: orientation change, keyboard appears/disappears).

var win = Ti.UI.createWindow();

var tableView = Ti.UI.createTableView();
win.add(tableView);

var tableRow = Ti.UI.createTableViewRow();
tableRow.add(Ti.UI.createTextField({width: '100%'}));
tableView.appendRow(tableRow);

win.open();
1. Run this application. 2. Focus the textfield and type some text. 3. Hide the keyboard OR rotate screen to trigger orientation change. Expected: selection position in textfield should be the same. Actual: selection position is reset to 0 (start).

Comments

  1. Lee Morris 2017-06-27

    I am unable to reproduce this issue with the following environment; Pixel (7.1) Studio 4.9.0.201705302345 Ti SDK 6.1.1.v20170623141152 Appc NPM 4.2.9 Appc CLI 6.2.1 Ti CLI 5.0.13 Alloy 1.9.11 Arrow 2.0.0 Xcode 8.2 (8C38) Node v4.8.2 Java 1.8.0_131

JSON Source