01-30-2014 06:22 PM
I'm implementing a pull down to refresh functionality for an application. I used and tested out the code from a sample app here:
While testing the sample application and my application on a bb10 simulator, I've noticed that the scrollTop property of the parent div tag that contains the "pull-to-refresh" div tag seems to jump to 0 at random points. This causes the arrow animation to jitter and sometimes causes the application to believe that the user is no longer pulling.
I think it might be because I'm using a simulator and the mouse doesn't properly simulate a touch event but I don't know for sure since I don't have a z10 device to test the application on yet. Is anyone else having this issue???
Solved! Go to Solution.
02-03-2014 02:41 PM
That's the first time I've heard of this issue. However, if there is a legit defect in the sample, I'd like to know about it so we can fix it.
You could try connecting to remote web inspector, setting a watch on a variable representing the scroll position, and watch it in real time as you interact with the simulator.
02-04-2014 11:35 AM
I ran the sample app on a the simulator and outputted the scrollTop property of the "scroller" element inside the scroll event listener, here are the results:
scrollTop: -29 app.js:3 scrollTop: -33 app.js:3 scrollTop: -36 app.js:3 scrollTop: -38 app.js:3 scrollTop: -46 app.js:3 scrollTop: 0 app.js:3 scrollTop: -54 app.js:3 scrollTop: 0 app.js:3 scrollTop: -64 app.js:3 scrollTop: 0 app.js:3 scrollTop: -76 app.js:3 scrollTop: 0 app.js:3 scrollTop: -84 app.js:3 scrollTop: 0 app.js:3 scrollTop: -88 app.js:3 scrollTop: 0 app.js:3 scrollTop: -89 app.js:3 scrollTop: 0 app.js:3 scrollTop: -88 app.js:3
It seems like the scrollTop property of that div element is jumping to 0 at random times when I pull down. The same thing is happening with my application. I ran this on the 10.2.1.1925 simulator. Version 10.2.0.1791 of the simulator showed similar results.
02-10-2014 10:48 AM
I can confirm this behavior does not occur on a live device. That's unfortunate that it does on the simulator as it introduces some confusion over expected versus actual results.
I expect there is a timing issue with an event handler in the simulator.
Thanks for reporting this.