When scrolling quickly on a scrollableView the scroll event does not fire all the time. Here's an app.js that you can test:
var win = Titanium.UI.createWindow({ backgroundColor:'#fff' }); var views_arr = []; for(var i=0; i<10; i++){ views_arr[i] = Ti.UI.createView({ width: 200, height: 100, borderColor:'#000' }); var lbl = Titanium.UI.createLabel({ text:'view '+i, color:'#000', }); views_arr[i].add(lbl); } scrollableView = Titanium.UI.createScrollableView( { views: views_arr, top: 0, left: 0, right: 0, borderWidth: 0, showPagingControl:true }); scrollableView.addEventListener('scroll', function(e) { Ti.API.info("Image Scrolled current page: " + e.currentPage); }); win.add(scrollableView); win.open();When looking at the log:
[INFO] scrollable-event/1.0 (1.6.1.2fdc0c5) [INFO] Image Scrolled current page: 1 [INFO] Image Scrolled current page: 2 [INFO] Image Scrolled current page: 6 [INFO] Image Scrolled current page: 7 [INFO] Image Scrolled current page: 8This has been tested on Ti 1.6.1 and iPhone 4.2
A similar question: http://developer.appcelerator.com/question/86241/titaniumuiscrollableview-not-firing-event-in-view-change
1 Answer
I've added a ticket (because this is a bug) in lighthouse
Your Answer
Think you can help? Login to answer this question!