这是indexloc提供的服务,不要输入任何密码
Skip to content

Fix problem with right-clicking on a right-to-left selection #80186

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

Merged

Conversation

ludwiktrammer
Copy link
Contributor

@ludwiktrammer ludwiktrammer commented Apr 10, 2021

Fixes #80119, #79592. Right clicking on a selection that was created from right-to-left will now work the same as left clicking on a selection that was created from left-to-right.

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, including Features we expect every widget to implement.
  • I signed the CLA.
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@flutter-dashboard flutter-dashboard bot added the framework flutter/packages/flutter repository. See also f: labels. label Apr 10, 2021
@google-cla google-cla bot added the cla: yes label Apr 10, 2021
@ludwiktrammer ludwiktrammer changed the title Fix problem with left-clicking on a right-to-left selection Fix problem with right-clicking on a right-to-left selection Apr 10, 2021
Copy link
Contributor

@LongCatIsLooong LongCatIsLooong left a comment

Choose a reason for hiding this comment

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

LGTM thanks for the fix!

@@ -487,6 +487,48 @@ void main() {
expect(renderEditable.selectPositionAtCalled, isTrue);
});

testWidgets('TextSelectionGestureDetectorBuilder right click', (WidgetTester tester) async {
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: indentation

Copy link
Contributor

Choose a reason for hiding this comment

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

Also could you add a comment to this test that says it's a regression test for #80119, for posterity?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thank you for the review! Both issues are now fixed.

Copy link
Contributor

@chunhtai chunhtai left a comment

Choose a reason for hiding this comment

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

LGTM

@ithinkso117
Copy link

What the status of this PR? We need this PR.... Please...

@LongCatIsLooong
Copy link
Contributor

I'm not sure if the test failures (especially the customer testing failures) are flakes. @ludwiktrammer could you sync the PR to HEAD and push again, see if the issues persist?

@ludwiktrammer
Copy link
Contributor Author

@LongCatIsLooong Done. This time the checks have passed successfully :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
framework flutter/packages/flutter repository. See also f: labels.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SelectableText focus issue
5 participants