Skip to content

Enhance the pointers and touches handling - #1256

Merged
dr1rrb merged 137 commits into
masterfrom
feature/iosTouches
Oct 11, 2019
Merged

dr1rrb merged 137 commits into
masterfrom
feature/iosTouches

Conversation

@dr1rrb

@dr1rrb dr1rrb commented Jul 17, 2019 •

Copy link
Copy Markdown
Member

GitHub Issue (If applicable):
#1162
#864
#1227
#643
#221 (Preliminary work only)
Fixes #1257

Refactor the touches for iOS, Android and WebAssembly

  • Bugfix
  • Feature

What is the current behavior?

We face multiple issues relative to pointers and gestures (like Tapped and DoubleTapped) events:

  • They are not raised following the same sequence as UWP
  • Lots of properties are not implemented (like the state of the pressed buttons)
  • Button.Click is confused with the Tapped event (leading to invalid event sequence)
  • The slider is not able to properly "capture" the pointers so when placed in a ScrollViewer it's almost un-usable
  • The Tapped and DoubleTapped events are implemented using iOS's gesture recognizers which interffers with the ScrollViewer

What is the new behavior?

  • The PointerXXX events are now raised in the same sequence as UWP are used as the source for all "interpreted" events (like Click, Tapped and DoubleTapped).
  • We no longer use the native gesture recognizers which alters the Touches<Began|Moved|Ended|Cancelled> on sub views
  • We now support the ClickMode on button
  • Pointer captures are now following the UWP behavior and PointerCaptureLost is now raised properly
  • All events which uses RoutedEventArgs are now fullfilling the OriginalSource

PR Checklist

@dr1rrb dr1rrb added kind/bug Something isn't working kind/enhancement New feature or request do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. platform/ios 🍎 Categorizes an issue or PR as relevant to the iOS platform labels Jul 17, 2019
@dr1rrb dr1rrb self-assigned this Jul 17, 2019
@dr1rrb
dr1rrb requested review from carldebilly, davidjohnoliver and jeromelaban and removed request for jeromelaban July 17, 2019 18:16

@davidjohnoliver davidjohnoliver left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work!

@davidjohnoliver

Copy link
Copy Markdown
Contributor

Release notes?

@dr1rrb
dr1rrb force-pushed the feature/iosTouches branch from 8b85d30 to 9dcbf24 Compare July 17, 2019 21:18
@dr1rrb

dr1rrb commented Jul 18, 2019

Copy link
Copy Markdown
Member Author

/azp run

Comment thread src/Uno.UWP/UI/Input/TappedEventArgs.cs Resolved

@carldebilly carldebilly left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Big PR. Good job!

@dr1rrb

dr1rrb commented Aug 2, 2019

Copy link
Copy Markdown
Member Author

/azp run

@dr1rrb
dr1rrb force-pushed the feature/iosTouches branch from 132a809 to c04a6bb Compare August 8, 2019 21:20
@dr1rrb

dr1rrb commented Aug 9, 2019

Copy link
Copy Markdown
Member Author

/azp run

@dr1rrb
dr1rrb force-pushed the feature/iosTouches branch from 49b2f8c to 800cf49 Compare August 13, 2019 21:07
@dr1rrb
dr1rrb force-pushed the feature/iosTouches branch from 5f58569 to 4466e24 Compare August 22, 2019 21:15
@dr1rrb dr1rrb mentioned this pull request Aug 23, 2019
1 of 4 tasks

@carldebilly carldebilly left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dr1rrb
dr1rrb force-pushed the feature/iosTouches branch 3 times, most recently from 5fd13b8 to 0669ab7 Compare August 27, 2019 00:52
@dr1rrb
dr1rrb force-pushed the feature/iosTouches branch from 97360c6 to 8def8ea Compare October 10, 2019 22:50
Comment thread doc/ReleaseNotes/_ReleaseNotes.md Resolved
Comment thread doc/articles/features/routed-events.md Resolved
Comment thread doc/articles/features/routed-events.md Resolved
Comment thread doc/articles/features/routed-events.md Resolved
Comment thread doc/articles/features/routed-events.md Resolved
Comment thread doc/articles/features/routed-events.md Resolved
Comment thread doc/articles/features/routed-events.md Resolved
Comment thread doc/articles/features/routed-events.md Resolved
Comment thread doc/articles/features/routed-events.md Resolved
Dr.Rx and others added 2 commits October 10, 2019 20:36
@dr1rrb
dr1rrb force-pushed the feature/iosTouches branch from 49c1706 to 82e146f Compare October 11, 2019 00:43
Comment thread doc/ReleaseNotes/_ReleaseNotes.md Resolved
@dr1rrb

dr1rrb commented Oct 11, 2019 •

Copy link
Copy Markdown
Member Author

@davidjohnoliver

Release notes?

@carldebilly

Documentation needs to be updated.
https://github.com/unoplatform/uno/blob/master/doc/articles/features/routed-events.md

Doc updated https://github.com/unoplatform/uno/pull/1256/files#diff-22bbf8f60bf82453e06800aaa19bed33R181 😎

GitHub
Build Mobile, Desktop and WebAssembly apps with C# and XAML. Today. Open source and professionally supported. - unoplatform/uno
GitHub
GitHub Issue (If applicable): #1162 #864 #1227 #643 #221 (Preliminary work only) Fixes #1257 Refactor the touches (on iOS only at this point)

Bugfix
Feature

What is the current behavior?
We face ...

@dr1rrb dr1rrb added the platform/wasm 🌐 Categorizes an issue or PR as relevant to the WebAssembly platform label Oct 11, 2019
Comment thread src/Uno.UI/UI/Xaml/RoutedEvent.cs Resolved
Comment thread src/Uno.UI/UI/Xaml/RoutedEventFlag.cs Resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/automation Categorizes an issue or PR as relevant to project automation area/build Categorizes an issue or PR as relevant to build infrastructure kind/bug Something isn't working kind/enhancement New feature or request platform/ios 🍎 Categorizes an issue or PR as relevant to the iOS platform platform/wasm 🌐 Categorizes an issue or PR as relevant to the WebAssembly platform

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Android] Pointer Events are not working properly

7 participants