Titanium.UI.ScrollableView not firing event in view change
How can I capture the the swipe event when I switch between views. The swipe event doesnt not fire all the time in the iphone simulator.
newsScrolView.addEventListener('swipe',function(e){
Titanium.API.info(newsScrolView.currentPage);
});
Even when the swipe event is fired, I get the previous view as the current Page values. Is there a correct way to get this done. I need to get a event fired when I user switches between views. And when the event is fired i need to know the currentPage.
2 Answers
-
Use the scroll event instead of the swipe event.
-
aren't you getting a focus event on the new view when it becomes active/focused?