Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-7331] Android: Picker nested in TableView Row not working

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2012-03-16T22:48:26.000+0000
Affected Version/sRelease 1.8.0.1, Release 2.0.0
Fix Version/sSprint 2012-03, Release 2.0.0, Release 1.8.2
ComponentsAndroid
Labelsmodule_tableviewrow, qe-testadded, regression
ReporterEduardo Gomez
AssigneeBill Dawson
Created2012-01-23T07:10:05.000+0000
Updated2012-07-23T14:54:19.000+0000

Description

Problem

Under Ti SDK 1.8.0.1 a Ti.UI picker control hosted in a table view row does not render above the active window, but rather below it.

Use to work on 1.7.5 (as seen in screen_1.7.5.jpg).

Steps to reproduce

1) Run code below 2) Click one of the row's buttons to open a new window. 3) Click one of the row's pickers - it does not open the picker row options, when it should do - it works fine in Ti SDK 1.7.5. 4) Now navigate back using the back button - you see the picker options from the previous window briefly before being destroyed as the previous window closes (as seen in screen_1.8.0.1.jpg).

Expected behavior

See fully operational Pickers whose options render above, rather than below the current window

Repro sequence

var browserWin = require('browser').browserWin;
var browser = new browserWin();
browser.open();
var browserWin = function() {
    var win = Ti.UI.createWindow({
        navBarHidden : true,
    });

    // tableview
    var data = [];

    for(var i = 10 - 1; i >= 0; i--) {

        // create row
        var row = Ti.UI.createTableViewRow({
        });

        // create and add a button
        var button = Ti.UI.createButton({
            title : 'Open new window',
            left:0
        });
        button.addEventListener('click', function(e) {
            var browserWin = require('browser').browserWin;
            var browser = new browserWin();
            browser.open();
        });
        row.add(button);

        // create and add a button
        var picker = Ti.UI.createPicker({
            selectionIndicator : true,
            right : 0
        });
        var pickerRow = Ti.UI.createPickerRow({
            title : 'option 1'
        });
        picker.add(pickerRow);
        row.add(picker);

        data.push(row);
    };

    var tableView = Ti.UI.createTableView({
        data : data
    });

    win.add(tableView);
    return win;

}
// export statements
exports.browserWin = browserWin;

Attachments

FileDateSize
screen_1.7.5.jpg2012-01-23T07:10:05.000+000051595
screen_1.8.0.1.jpg2012-01-23T07:10:05.000+000038697
screen1.jpg2012-01-23T07:10:05.000+000041751

Comments

  1. Ivan Skugor 2012-01-23

    Awesome ... I noticed same issue, but didn't figure out why it's happening.
  2. Bill Dawson 2012-02-09

    Pull request ready https://github.com/appcelerator/titanium_mobile/pull/1385
  3. Wilson Luu 2012-02-09

    Closing bug. Verified fix on: SDK build: 1.9.0.v20120209144634 Runtime: V8, Rhino Titanium Studio, build: 1.0.8.201201262211 Device: Nexus 1 (2.2.2)

JSON Source