Skip to content
This repository has been archived by the owner on Oct 8, 2021. It is now read-only.

Feature Request: Swipeup and Swipedown #1669

Closed
VTWoods opened this issue May 19, 2011 · 11 comments
Closed

Feature Request: Swipeup and Swipedown #1669

VTWoods opened this issue May 19, 2011 · 11 comments

Comments

@VTWoods
Copy link
Contributor

VTWoods commented May 19, 2011

There is alot of helpful code in jquery.mobile.event.js for interpreting swipe events. However, if you want to catch a swipeup or swipedown event you have to recreate the swiperight and swipeleft logic. I wrote a patch that added swipe up and swipe down to the supported events. However, I was not sure if these events were not included intentionally. If this is a feature that the devs are interested, I could initiate a pull request.

@VTWoods
Copy link
Contributor Author

VTWoods commented May 20, 2011

This change enabled me to create a "remote control" web app that allowed me to send up, down, left, and right signals to a server.

For reference:
https://github.com/VTWoods/jquery-mobile/blob/touchEvents/js/jquery.mobile.event.js

If there is a better way to pass around the start and stop information, I would be happy to make the modification.

@toddparker
Copy link
Contributor

So this could only be used on an app that doesn't have scrolling, right? The up/down swipe would kill that.

@VTWoods
Copy link
Contributor Author

VTWoods commented May 20, 2011

In my application I had a blank page with touchmove default disabled.

@VTWoods
Copy link
Contributor Author

VTWoods commented May 20, 2011

I tested my change without touchmove disabled and the swipeup and swipedown are still fired properly.

@VTWoods
Copy link
Contributor Author

VTWoods commented May 22, 2011

Instead of adding swipeup and swipedown, the swipe event could be triggered for any swipe motion with the movement info added as event parameters.

@toddparker
Copy link
Contributor

Cool. I don't think this will be considered for 1.0 so could you add a link to this issue from the feature request wiki page, then close this issue for now? Thanks!

@VTWoods
Copy link
Contributor Author

VTWoods commented May 23, 2011

Yup no problem.

@VTWoods VTWoods closed this as completed May 23, 2011
@emilesilvis
Copy link

Was this ever implemented?

@trgraglia
Copy link

@mrextreme
Copy link

This feature is badly missing. "pull down to refresh", to name the most important of all of the use cases. It is practically an expected behaviour since Twitter and Facebook made is popular and widely used, and that's exactly what I would need to implement now, for that very reason. None of the 3rd party swipe event solutions work properly, they block or clog the event chain badly, don't work at all or make scrolling choppy.

@arschmitz
Copy link
Contributor

@mrextreme swipeup and down are very different then pull to refresh. Pull to refresh would require a draggable implementation to do properly. Also the reason none of the 3rd party solution work well is because with the current state of Touch / Pointer events in many browsers this is not possible to do in a cross browser way with out the issues you mention. There is a lot of discussion about this and the issues surrounding it in the pointer events working group. Things like the facebook app are using native events which make this possible to do smoothly.

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

No branches or pull requests

6 participants