-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
Recommended implementation of combining characters implementation. #7758
Recommended implementation of combining characters implementation. #7758
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This all makes sense, thanks! Did you want to finish it, or would you rather I moved this into my PR and finished it up? Either way is fine for me.
shell/platform/android/io/flutter/embedding/engine/android/AndroidKeyProcessor.java
Outdated
Show resolved
Hide resolved
shell/platform/android/io/flutter/embedding/engine/android/AndroidKeyProcessor.java
Outdated
Show resolved
Hide resolved
shell/platform/android/io/flutter/embedding/engine/android/AndroidKeyProcessor.java
Outdated
Show resolved
Hide resolved
shell/platform/android/io/flutter/embedding/engine/systemchannels/KeyEventChannel.java
Show resolved
Hide resolved
@gspencergoog I can go ahead and clean this up and pending your final review we can merge this in. Other than your comments above, is there anything else that needs to be addressed before you'd be happy with a merge? |
Ok, sounds good. The only other thing I can think of to address is having a test. |
Unfortunately, we still have no testing infrastructure in the engine embedding. Literally none of the Java code is tested.... |
OK, then that's it, I guess. Thanks! |
@gspencergoog I gave it another pass. Please let me know if the comments, names, and implementation look acceptable. |
shell/platform/android/io/flutter/embedding/engine/android/AndroidKeyProcessor.java
Outdated
Show resolved
Hide resolved
shell/platform/android/io/flutter/embedding/engine/android/AndroidKeyProcessor.java
Outdated
Show resolved
Hide resolved
Made requested changes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Modulo the one small nit. Thanks!
shell/platform/android/io/flutter/embedding/engine/android/AndroidKeyProcessor.java
Outdated
Show resolved
Hide resolved
flutter/engine@3a1a604...4663d35 git log 3a1a604..4663d35 --no-merges --oneline 4663d35 Recommended implementation of combining characters implementation. (flutter/engine#7758) d521212 Revert "Roll src/third_party/dart fdfe40ea95..de2e7e7721 (7 commits)" (flutter/engine#7789) a003c46 Roll src/third_party/dart fdfe40ea95..de2e7e7721 (7 commits) The AutoRoll server is located here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+/master/autoroll/README.md If the roll is causing failures, please contact the current sheriff (chinmaygarde@google.com), and stop the roller if necessary.
This is a recommended approach to achieve the behavior in #7722 without introducing state into the KeyEventChannel.
The approach in this recommendation roughly follows the breakdown that can be seen between
TextInputPlugin
andTextInputChannel
as well asAccessibilityBridge
andAccessibilityChannel
. At the moment those examples are only visible, themselves, in another PR:#7738
Specific recommendations in this PR:
FlutterKeyEvent
which explicitly declares all of the information that Flutter might want for a key event, regardless of what Android reports in its standardKeyEvent
combiningCharacters
tobaseCharacter
based on my reading of the javadocs. That might be wrong. The crux of the issue is that I'm not (and probably most people are not) familiar with this level of key encoding behavior. Therefore, I would recommend excessively commenting this new code with links to relevant docs and/or explanations of these concepts that an average reader may have never heard of.