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

Disable touch device swiping? #60

Closed
Shpigford opened this issue Dec 28, 2011 · 2 comments
Closed

Disable touch device swiping? #60

Shpigford opened this issue Dec 28, 2011 · 2 comments

Comments

@Shpigford
Copy link

How can I prevent swiping between slides on touch devices?

I only want to switch between slides using previous/next links (enabled using deck.navigation).

@imakewebthings
Copy link
Owner

I've scoped the events within a different namespace for each of the modules, so the following shouldn't effect any other touch events you may want to keep (like the deck.menu double tap):

$.deck('.slide');
// Include the next line after your init call above
$.deck('getContainer').off('touchstart.deck touchmove.deck touchend.deck');
// Use .unbind instead of .off if using jQuery < 1.7

@Shpigford
Copy link
Author

Perfect! Exactly what I needed. Thanks so much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants