Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Convert Gfx PlatformView to use modern TouchSource API #32877

Merged
merged 1 commit into from
Apr 30, 2022

Conversation

jaeheon
Copy link
Contributor

@jaeheon jaeheon commented Apr 22, 2022

This PR switches the GfxPlatformView code to use the TouchSource/MouseSource API. After this PR, both GFX and Flatland will receive touch and mouse events over the new APIs, instead of the legacy GFX SessionListener API.

GFX uses TouchSource

Test re-enabled: PlatformViewTests.TouchSourceLogicalToPhysicalConversion

This PR has been manually validated on a sherlock device running production code, with the following UI cases:

  • ordinary usage of the System UI
  • with child view (YouTube), bring up settings (Sys UI)
  • with a partial-scren child view (Duo) interrupting another full-screen child view (YT), and both are still responsive to touch

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read and followed the [Flutter Style Guide] and the [C++, Objective-C, Java style guides].
  • I listed at least one issue that this PR fixes in the description above.
  • I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt. See [testing the engine] for instructions on
    writing and running engine tests.
  • I updated/added relevant documentation (doc comments with ///).
  • I signed the [CLA].
  • All existing and new tests are passing.

@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact Hixie on the #hackers channel in Chat (don't just cc him here, he won't see it! He's on Discord!).

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing.

@akbiggs
Copy link
Contributor

akbiggs commented Apr 22, 2022

Test re-enabled: PlatformViewTests.TouchSourceLogicalToPhysicalConversion is this done in this PR? I don't see changes to test code.

Copy link
Contributor

@akbiggs akbiggs left a comment

Choose a reason for hiding this comment

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

Recommend rebasing on upstream/master before submission.

@jaeheon
Copy link
Contributor Author

jaeheon commented Apr 22, 2022

Test re-enabled: PlatformViewTests.TouchSourceLogicalToPhysicalConversion is this done in this PR? I don't see changes to test code.

Yes, see shell/platform/fuchsia/flutter/platform_view_unittest.cc - the "DISABLED_" string is gone

@akbiggs
Copy link
Contributor

akbiggs commented Apr 22, 2022

Oh, it's because your other commit hasn't submitted yet so that Disabled_ string doesn't appear in the diff.

@jaeheon jaeheon added the waiting for tree to go green This PR is approved and tested, but waiting for the tree to be green to land. label Apr 30, 2022
@fluttergithubbot fluttergithubbot merged commit 863f646 into flutter:main Apr 30, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Apr 30, 2022
@jaeheon jaeheon deleted the gfx-touch-source branch May 2, 2022 20:11
jaeheon added a commit to jaeheon/engine that referenced this pull request Jul 29, 2022
jaeheon added a commit that referenced this pull request Aug 1, 2022
)

Original PR: #32877

Revert of #32877: commit 1965c92 (#33471)

*This* patch: Revert of #33471

fxbug.dev/85125
betrevisan pushed a commit to betrevisan/engine that referenced this pull request Aug 5, 2022
emilyabest pushed a commit to emilyabest/engine that referenced this pull request Aug 12, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
needs tests platform-fuchsia waiting for tree to go green This PR is approved and tested, but waiting for the tree to be green to land.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants