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

Adding support for UIScreenEdgePanGestureRecognizer via existing on_pan helper #211

Merged
merged 7 commits into from Jul 27, 2016

Conversation

dchersey
Copy link
Contributor

I needed to use a pan gesture recognizer that only recognizes gestures from the edges.
I thought it would be simples from an API perspective to add an :edges option to the existing on_pan method from gestures.

If the edges option is present, and is anything other than [:none], we use the UIScreenEdgePanGestureRecognizer instead of the UIPanGestureRecognizer.

It is not valid to specify fingers options or count for the edge recognizer in IOS so I ignore any of those options if specified along with :edges.

@colinta
Copy link
Contributor

colinta commented Jul 26, 2016

Looks good! I like the on_pan(edges: []) syntax. Can you just add some specs to gestures_specs.rb and symbol_constants_specs.rb, and maybe a note about usage in the README?

@dchersey
Copy link
Contributor Author

Done!

@colinta
Copy link
Contributor

colinta commented Jul 27, 2016

I tested locally, and actually I did see some strange failures, they were all in date and location additions. So GTG!

@colinta colinta merged commit a4cd978 into rubymotion-community:master Jul 27, 2016
@colinta
Copy link
Contributor

colinta commented Jul 27, 2016

Available in 3.4.0

@dchersey
Copy link
Contributor Author

Yes, I saw those too ... I thought it was me :s

On Wed, Jul 27, 2016 at 4:03 PM Colin T.A. Gray notifications@github.com
wrote:

Available in 3.4.0


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#211 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAw2iRe-8mup6CRBtKacvUVg9NEAEm-7ks5qZ7mIgaJpZM4JVZdu
.

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

Successfully merging this pull request may close these issues.

None yet

2 participants