On Wed, Jan 5, 2011 at 9:49 AM, Balázs Galambosi <[email protected]>wrote:
> > 1. register `touchstart` event handler, save the position and use it > to calculate if > the movement goes beyond the threshold (instead of the delta from the > last > `move` event.). > > I'm already doing that... I've just pushed it live so you can see it here: http://labs.millermedeiros.com/js/ios_widgets/scrollPane.html what I wanted to do is to lock the browser native vertical scroll if the user does a swipe gesture that isn't precisely horizontal (ie: -30 > changeY < 30) and re-enable it after changeY leaves this threshold... the problem is that after preventing the default action of the touchmove event (scroll the browser window) I can't re-enable the browser default action... (trapping the user) until now I didn't had chance to try to clone the event and probably won't have time to do it on the next couple days since it is just a small detail (and nobody complained about it) it isn't on my priority list... asked the list to save time and to know if anyone know if it is possible to do it. PS: if you don't have an iPhone you can try it on Chrome (just click and drag horizontally) but you wont notice the scrolling happening together with the swipe. PS2: the source code is a mess... I have to refactor it someday.. -- To view archived discussions from the original JSMentors Mailman list: http://www.mail-archive.com/[email protected]/ To search via a non-Google archive, visit here: http://www.mail-archive.com/[email protected]/ To unsubscribe from this group, send email to [email protected]
