Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-15939] iOS7: OptionDialog can't scroll correctly

GitHub Issuen/a
TypeBug
PriorityCritical
StatusClosed
ResolutionFixed
Resolution Date2013-12-10T19:22:43.000+0000
Affected Version/sRelease 3.1.3
Fix Version/s2013 Sprint 25, 2013 Sprint 25 API, Release 3.2.0, Release 3.3.0
ComponentsiOS
Labelsqe-closed-3.2.0, qe-testadded, supportTeam, triage
ReporterEduardo Gomez
AssigneeVishal Duggal
Created2013-12-10T14:34:42.000+0000
Updated2014-01-22T09:54:17.000+0000

Description

Issue description

OptionDialog isn't scrolling correctly. This is only reproducible at iPad. iPhone 4 devices does not seem affected.

Steps to reproduce

If you press the button and see the optionsDialog that displays and then try to scroll, you will notice that it looks like 2 lists, one that stays still and the other that actually scrolls (please see screen shoot attached).

Runnable sample

var win = Ti.UI.createWindow({
    backgroundColor: 'white'
});

var btn = Ti.UI.createButton({
    title: 'here'
});

btn.addEventListener('click', function(){

var optionsArray = new Array;

for (loopCount = 0; loopCount < 150; loopCount++) {
    optionsArray[loopCount] = 'Name of the person, item ' + loopCount;
}

var dialog = Ti.UI.createOptionDialog({
    title: 'select something...',
    options: optionsArray,
    cancel: -1,
});

dialog.items = new Object();
dialog.addEventListener('click', function(b) {

});

dialog.show();
});

win.add(btn);
win.open();

Attachments

FileDateSize
iOS Simulator Screen shot Dec 9, 2013 3.18.07 PM.png2013-12-10T14:34:43.000+0000174299

Comments

  1. Vishal Duggal 2013-12-10

    Introduced new property opaquebackground. Test Case
       var win = Ti.UI.createWindow({
           backgroundColor: 'white'
       });
        
       var btn = Ti.UI.createButton({
           title: 'here'
       });
        
       btn.addEventListener('click', function(){
        
       var optionsArray = new Array;
        
       for (loopCount = 0; loopCount < 150; loopCount++) {
           optionsArray[loopCount] = 'Name of the person, item ' + loopCount;
       }
        
       var dialog = Ti.UI.createOptionDialog({
           title: 'select something...',
           options: optionsArray,
           cancel: -1,
           opaquebackground:true
       });
        
       dialog.items = new Object();
       dialog.addEventListener('click', function(b) {
        
       });
        
       dialog.show();
       });
        
       win.add(btn);
       win.open();
       
  2. Vishal Duggal 2013-12-10

    Pull pending against master https://github.com/appcelerator/titanium_mobile/pull/5107 Backport to 3_2_X https://github.com/appcelerator/titanium_mobile/pull/5108
  3. Samuel Dowse 2013-12-11

    Verified fixed on: Mac OSX 10.9 Mavericks Titanium Studio, build: 3.2.0.201312091613 Titanium SDK, build: 3.2.0.v20131210112451 CLI: 3.2.0-cr Alloy: 1.3.0-cr iOS Device: iPhone 5S (7.0) Tested using both code from description and comment. Both work as expected. Closing.

JSON Source