Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Current frame "jumps" on screen hold in iOS6 with Safari #260

Open
trecord opened this issue Feb 21, 2014 · 4 comments
Open

Current frame "jumps" on screen hold in iOS6 with Safari #260

trecord opened this issue Feb 21, 2014 · 4 comments
Assignees
Milestone

Comments

@trecord
Copy link

trecord commented Feb 21, 2014

I've noticed that on my iPad with iOS6 and Safari, reel will often "jump" from the current frame to another far from where the user was if the user presses and "holds"* on the screen. It seems to be specific to iOS6 and earlier: I tried on a device with iOS7, and wasn't able to recreate this issue. I recreated this with reel's demo pages.

*By "hold" I mean touching the screen in an area where reel is active for a second or so without moving your finger.

@pisi
Copy link
Owner

pisi commented Feb 28, 2014

Interesting. Replicated on iOS5 too, so far seems isolated to Safari only. Chrome on iPad1 works fine. Thank you for making me aware of this! Investigating more...

@pisi pisi added the bug label Feb 28, 2014
@pisi pisi added this to the 1.3.1 milestone Feb 28, 2014
@pisi pisi self-assigned this Feb 28, 2014
pisi added a commit that referenced this issue Mar 28, 2014
…iOS for example), if handler is triggered from by touch it "locks" to it and will ignore any non-touch events including touch-mouse, which will follow. `up` event releases this lock after 30 ticks (<1s) to prevent further `mouseup` event from spoiling the touch interaction. #260
pisi added a commit that referenced this issue Mar 28, 2014
@pisi
Copy link
Owner

pisi commented Mar 28, 2014

OK, as far as I could tell, this was a rather unpleasant side effect of changes made in #233. Since then both touch* and mouse* events are bound together to allow for devices with both mouse and touch. Before that the binding was conditional on touch feature detection. Evidently this configuration does not work well with tablets where a touch interaction triggers both touch AND mouse event. It causes handlers to be double-triggered and resulting in issues like yours.

Now I scrutinize the events and basically suppress mouse events closely following touch events., which resulted in fixed iPad issues and even slightly improved performance.

@trecord, Please help me test this fix by grabbing the patched code from gh-260-touch-fix branch and testing on your setup and device. Thanks!

@trecord
Copy link
Author

trecord commented Mar 28, 2014

Hi Petr, I just uploaded the new build and gave it a quick test on an iOS6 device in Safari. I can confirm that it's fixed.

@pisi
Copy link
Owner

pisi commented Mar 29, 2014

That was quick! Thank you @trecord

@pisi pisi added the verified label Mar 29, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants