mirror of
https://github.com/fcitx5-android/fcitx5-android.git
synced 2026-08-02 04:44:35 +08:00
Send arrow key in browser location bar on space swipe (#872)
location bar needs right arrow key to confirm URL suggestion see also bugzilla.mozilla.org/show_bug.cgi?id=1999915 Co-authored-by: Rocka <i@rocka.me>
This commit is contained in:
parent
da9980d79f
commit
630f9258dc
@ -392,7 +392,12 @@ class FcitxInputMethodService : LifecycleInputMethodService() {
|
||||
}
|
||||
|
||||
private fun handleArrowKey(keyCode: Int) {
|
||||
if (currentInputEditorInfo.inputType and InputType.TYPE_MASK_CLASS == InputType.TYPE_NULL) {
|
||||
val type = currentInputEditorInfo.inputType and InputType.TYPE_MASK_CLASS
|
||||
val variation = currentInputEditorInfo.inputType and InputType.TYPE_MASK_VARIATION
|
||||
if (type == InputType.TYPE_NULL ||
|
||||
// confirm URL suggestion in browser location bar, see also https://bugzilla.mozilla.org/show_bug.cgi?id=1999915
|
||||
type == InputType.TYPE_CLASS_TEXT && variation == InputType.TYPE_TEXT_VARIATION_URI
|
||||
) {
|
||||
sendDownUpKeyEvents(keyCode)
|
||||
return
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user