Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-20138

Consecutive calls to ScrollableView.setViews causes the app to become unresponsive

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: Release 5.1.0, Release 5.1.1
    • Fix Version/s: Release 5.2.0
    • Component/s: iOS
    • Environment:

      Mobile SDK v. 5.1.0.GA/5.1..GA
      iOS 9

    • Story Points:
      8
    • Sprint:
      2016 Sprint 1 SDK

      Description

      Following a typical cycle of having a default view inside a scrollable view and then updating it calling setViews() fails and causes the app to become unresponsive. Tested on iOS > 8.4

      Same effect if you try with a very short delay between the two calls.
      Code below works fine in 5.0.2.GA but not in 5.1.0/5.1.1

      (function() {
      	var window = Ti.UI.createWindow();
      	
      	var mainView = Ti.UI.createView({
      		backgroundColor:'#fff',
      		width:Ti.UI.FILL,
      		height:Ti.UI.FILL
      	});
      		
      	var scrollableView = Ti.UI.createScrollableView({
      		borderColor:'green',
      		views:undefined,
      		width:Ti.UI.FILL,
      		height:'60%'
      	});
      	
      	var viewA = Ti.UI.createView({
      		backgroundColor:'black'
      	});
      	var colors = ['red', 'green', 'blue'];	
      	var viewsB = [];
      	for(var i = 0;i<3;i++){
      		viewsB.push(Ti.UI.createView({
      			backgroundColor:colors[i]
      		}));
      	}	
      	scrollableView.setViews([viewA]);
      	mainView.add(scrollableView);
      	window.add(mainView);
      	window.open();
      	scrollableView.setViews(viewsB);	
      })();
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                penrique Pedro Enrique (Inactive)
                Reporter:
                nipoul Nikos Poulios
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

                  • Titanium SDK/CLI <> Titanium Mobile
                    Synced with:
                    TIMOB-20781
                    Sync status:
                    ERROR
                    Last received:
                    Last sent:

                    Git Source Code