Fix Linux numpad shortcuts on web#148988
Conversation
7234146 to
b8c3f3c
Compare
7d54c57 to
c013eb1
Compare
justinmc
left a comment
There was a problem hiding this comment.
LGTM 👍 . Tricky catch. Thanks for the thorough tests.
There was a problem hiding this comment.
Nit: Typically I'd see the closing parenthesis on the next line. Here and below.
There was a problem hiding this comment.
I did it on purpose because the analyzer was failing and complaining about skip requiring a comment.
I tried various format and that one was ok.
After seeing your comment, I had a closer look to the analyzer failure and, base on https://github.com/flutter/flutter/wiki/Tree-hygiene#skipped-tests, I figured out that the lint is about having an URL or [intended] in the comment, knowing this I was able to update the PR with a proper formatting.
c013eb1 to
4791efa
Compare
4791efa to
8069001
Compare
|
"Thanks, @bleroux This is helpful." |
flutter/flutter@cb26a01...6564471 2024-05-26 [email protected] Roll Flutter Engine from a207dfe8e96b to f3025ae1511b (1 revision) (flutter/flutter#149098) 2024-05-25 [email protected] Manual roll Flutter Engine from 1d154ff93a87 to a207dfe8e96b (10 revisions) (flutter/flutter#149096) 2024-05-25 [email protected] Fix Linux numpad shortcuts on web (flutter/flutter#148988) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC [email protected],[email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
## Description This PRs fixes a Web issue on Linux related to numpad keys. In flutter#145464, I introduced numpad shortcuts for Linux. These shortcuts work well on a desktop Linux application but they broke the Linux+Web numpad logic. When I added these shortcuts, I expected them to not be active on Web (because I knew that on Web, those shortcuts are handled by the browser). But there is a trick: text editing shortcuts are still defined on Web but they are disabled at the editable text level so one can use them in components that are not `EditableText` (see flutter#103377). In this PR, I used the same approach than for other text editing shortcuts: when on web associate those shortcuts to the `DoNothingAndStopPropagationTextIntent` intent. ## Related Issue Fixes flutter#148447. ## Tests Updates 2 tests. Adds 2 tests.
|
Will this be cherry-picked to the stable branch? Our product currently depends on this fix as many of our users rely on numpad functionality, and we're experiencing a significant blockage due to this issue. We might need to downgrade to a previous stable version of Flutter that does not have this problem. Thanks for your assistance! |
## Description This PRs fixes a Web issue on Linux related to numpad keys. In flutter#145464, I introduced numpad shortcuts for Linux. These shortcuts work well on a desktop Linux application but they broke the Linux+Web numpad logic. When I added these shortcuts, I expected them to not be active on Web (because I knew that on Web, those shortcuts are handled by the browser). But there is a trick: text editing shortcuts are still defined on Web but they are disabled at the editable text level so one can use them in components that are not `EditableText` (see flutter#103377). In this PR, I used the same approach than for other text editing shortcuts: when on web associate those shortcuts to the `DoNothingAndStopPropagationTextIntent` intent. ## Related Issue Fixes flutter#148447. ## Tests Updates 2 tests. Adds 2 tests.
Cherry pick request of #148988 to stable. Fixes an issue on Web+Linux that prevents users from inputting data using the numpad.
Description
This PRs fixes a Web issue on Linux related to numpad keys.
In #145464, I introduced numpad shortcuts for Linux. These shortcuts work well on a desktop Linux application but they broke the Linux+Web numpad logic.
When I added these shortcuts, I expected them to not be active on Web (because I knew that on Web, those shortcuts are handled by the browser). But there is a trick: text editing shortcuts are still defined on Web but they are disabled at the editable text level so one can use them in components that are not
EditableText(see #103377).In this PR, I used the same approach than for other text editing shortcuts: when on web associate those shortcuts to the
DoNothingAndStopPropagationTextIntentintent.Related Issue
Fixes #148447.
Tests
Updates 2 tests.
Adds 2 tests.