Skip to content

Conversation

@dkwingsmt
Copy link
Contributor

@dkwingsmt dkwingsmt commented May 1, 2019

Description

This PR is a reland of #31819.

Changes:

  • None yet.

Explanation

The previous attempt #31819 broke desktop embedders (see more discussion at #31884). It's likely because the embedder API does not send buttons at all, which is a requirement by gesture recognizers after this PR.

Related Issues

Tests

I added the following tests:

  • None

Checklist

Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes ([x]). This will ensure a smooth and quick review process.

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I signed the CLA.
  • I read and followed the Flutter Style Guide, including Features we expect every widget to implement.
  • I updated/added relevant documentation (doc comments with ///).
  • All existing and new tests are passing.
  • The analyzer (flutter analyze --flutter-repo) does not report any problems on my PR.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

Does your PR require Flutter developers to manually update their apps to accommodate your change?

  • Yes, this is a breaking change (Please read Handling breaking changes). Replace this with a link to the e-mail where you asked for input on this proposed change.
  • No, this is not a breaking change.

@dkwingsmt
Copy link
Contributor Author

+cc @stuartmorgan @jonahwilliams
(It's a placeholder PR; no changes have been added yet)

@stuartmorgan-g
Copy link
Contributor

I would suggest doing a separate PR that adds button data to the pointer data created in embedder.cc, landing that, and then re-landing your CL. Sending the button data shouldn't depend on your PR, so that lets you do a simple, easy-to-review PR for that aspect, rather than it being part of an already-large PR.

@goderbauer goderbauer added a: desktop Running on desktop framework flutter/packages/flutter repository. See also f: labels. labels May 6, 2019
@dkwingsmt
Copy link
Contributor Author

@jonahwilliams I've tested this PR on desktop and confirmed that the button responds to LMB click, and no longer to RMB click. The environment is as follow:

@dkwingsmt dkwingsmt changed the title WIP Redo#2: Add buttons to gestures Redo#2: Add buttons to gestures May 15, 2019
Copy link
Contributor

@jonahwilliams jonahwilliams left a comment

Choose a reason for hiding this comment

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

LGTM

@dkwingsmt dkwingsmt merged commit 7f969d0 into flutter:master May 20, 2019
@dkwingsmt dkwingsmt deleted the redo2-tap-buttons branch May 20, 2019 21:18
@wreppun
Copy link

wreppun commented Jul 13, 2019

@dkwingsmt , I created a ticket with some detail at #36118 , but I traced the broken scroll on the chromebook touchpad back to this PR.

properties.add(FlagProperty('wonArenaForPrimaryPointer', value: _wonArenaForPrimaryPointer, ifTrue: 'won arena'));
properties.add(DiagnosticsProperty<Offset>('finalPosition', _finalPosition, defaultValue: null));
properties.add(FlagProperty('sentTapDown', value: _sentTapDown, ifTrue: 'sent tap down'));
// TODO(tongmu): Add property _initialButtons and update related tests
Copy link
Contributor

Choose a reason for hiding this comment

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

is there any reason we couldn't do this as part of this PR when it landed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It was because that this PR was already big and at its 2nd redo, so I didn’t want to introduce unnecessary changes that affected a lot of files at that time. I’ll fix this.

cyanglaz pushed a commit that referenced this pull request Jul 17, 2020
#61671)

After #31935, Some one sequence gesture recognizers requires at least one callback to be able to compete in the arena. This PR adds the a no-op callback in the gesture recognizer in the platform view when the gesture recognizer does not have any callbacks. This way, all the gesture recognizers in the platform view can compete in the arena.
Pragya007 pushed a commit to Pragya007/flutter that referenced this pull request Aug 11, 2020
flutter#61671)

After flutter#31935, Some one sequence gesture recognizers requires at least one callback to be able to compete in the arena. This PR adds the a no-op callback in the gesture recognizer in the platform view when the gesture recognizer does not have any callbacks. This way, all the gesture recognizers in the platform view can compete in the arena.
mingwandroid pushed a commit to mingwandroid/flutter that referenced this pull request Sep 6, 2020
flutter#61671)

After flutter#31935, Some one sequence gesture recognizers requires at least one callback to be able to compete in the arena. This PR adds the a no-op callback in the gesture recognizer in the platform view when the gesture recognizer does not have any callbacks. This way, all the gesture recognizers in the platform view can compete in the arena.
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 4, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

a: desktop Running on desktop framework flutter/packages/flutter repository. See also f: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Desktop embedding mouse clicks do not register

7 participants