VR: Support web input editing
This CL overrides the InputMethodManagerWrapper that lives in
content/public/a/j/s/o/c/content/browser/input/ with a VR-specific
implementation that interfaces between content and the Daydream keyboard.
This way, we pretend that the Daydream keyboard is an IME keyboard when it
actually uses a completely different API. The keyboard talks to the content
via VrInputConnection (which directly calls methods on the existing
InputConnection).
This CL does the following refactoring:
- InputMethodManagerWrapper is added to content_public which is implemented
by InputMethodManagerWrapperImpl in the default case and
VrInputMethodManagerWrapper while in VR.
- ImeAdapter in content_public is extended to expose the active
InputConnection so that the VR keyboard can communicate with it.
Note that the actual logic is gated behind a runtime flag.
[email protected]
Bug: 641470
Cq-Include-Trybots: master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_vr;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel
Change-Id: If668f95bcdab8388ff2be5255adebf1f1837fcd1
Reviewed-on: https://chromium-review.googlesource.com/867513
Commit-Queue: Yash Malik <[email protected]>
Reviewed-by: Nick Carter <[email protected]>
Reviewed-by: Changwan Ryu <[email protected]>
Reviewed-by: Bo <[email protected]>
Reviewed-by: Amirhossein Simjour <[email protected]>
Cr-Commit-Position: refs/heads/master@{#538043}
diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc
index 730c250..83d247fa 100644
--- a/chrome/browser/flag_descriptions.cc
+++ b/chrome/browser/flag_descriptions.cc
@@ -2871,6 +2871,10 @@
const char kVrBrowserKeyboardDescription[] =
"Enable a virtual keyboard for Chrome VR.";
+const char kVrWebInputEditingName[] = "VR browsing web input editing";
+const char kVrWebInputEditingDescription[] =
+ "Allow editing web input fields while in VR mode.";
+
const char kVrBrowsingExperimentalFeaturesName[] =
"VR browsing experimental features";
const char kVrBrowsingExperimentalFeaturesDescription[] =