Commit 9bc823dd authored by Natalie Chouinard's avatar Natalie Chouinard Committed by Commit Bot

Show soft keyboard when omnibox focused

Explicitly show soft input keypboard on omnibox focus for search. Fixes
an issue with Duet, where the keyboard could be dismissed by the Back
or keyboard Action buttons, after which re-clicking the Search button
would focus the omnibox, but would not re-open the keyboard by default.

Bug: 981682
Change-Id: I1fe14edae4493dd57afe79250ad7fdbc806adcc5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1869530Reviewed-by: default avatarEnder <ender@google.com>
Reviewed-by: default avatarTheresa  <twellington@chromium.org>
Reviewed-by: default avatarMatthew Jones <mdjones@chromium.org>
Commit-Queue: Natalie Chouinard <chouinard@chromium.org>
Cr-Commit-Position: refs/heads/master@{#710973}
parent b6bce3cd
...@@ -994,6 +994,11 @@ public class LocationBarLayout extends FrameLayout ...@@ -994,6 +994,11 @@ public class LocationBarLayout extends FrameLayout
handleUrlFocusAnimation(mUrlHasFocus); handleUrlFocusAnimation(mUrlHasFocus);
} else { } else {
mUrlBar.requestFocus(); mUrlBar.requestFocus();
// Explicitly show soft keyboard (crbug.com/981682).
InputMethodManager imm = (InputMethodManager) getContext().getSystemService(
Context.INPUT_METHOD_SERVICE);
imm.showSoftInput(mUrlBar, 0);
} }
} else { } else {
assert pastedText == null; assert pastedText == null;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment