Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(295)

Unified Diff: ui/views/mus/window_tree_host_mus.cc

Issue 2412593002: IME for Mus: Send ack for key events after IME driver processes the event. (Closed)
Patch Set: Fixed views_mus_unittests. Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/views/mus/window_tree_host_mus.cc
diff --git a/ui/views/mus/window_tree_host_mus.cc b/ui/views/mus/window_tree_host_mus.cc
index caed894310e48e65017d0b3d2b56882ca5b1a22f..5b467f7e0d786fa31557fac3e38840238c1fd450 100644
--- a/ui/views/mus/window_tree_host_mus.cc
+++ b/ui/views/mus/window_tree_host_mus.cc
@@ -53,9 +53,6 @@ WindowTreeHostMus::WindowTreeHostMus(NativeWidgetMus* native_widget,
// TODO(sky): we need to transform for device scale though.
dispatcher()->set_transform_events(false);
compositor()->SetHostHasTransparentBackground(true);
-
- input_method_ = base::MakeUnique<InputMethodMus>(this, window);
- SetSharedInputMethod(input_method_.get());
}
WindowTreeHostMus::~WindowTreeHostMus() {
@@ -63,15 +60,9 @@ WindowTreeHostMus::~WindowTreeHostMus() {
DestroyDispatcher();
}
-void WindowTreeHostMus::InitInputMethod(shell::Connector* connector) {
- input_method_->Init(connector);
-}
-
void WindowTreeHostMus::DispatchEvent(ui::Event* event) {
- if (event->IsKeyEvent() && GetInputMethod()) {
- GetInputMethod()->DispatchKeyEvent(event->AsKeyEvent());
- return;
- }
+ // Key events are sent to InputMethodMus directly from NativeWidgetMus.
+ DCHECK(!event->IsKeyEvent());
WindowTreeHostPlatform::DispatchEvent(event);
}
« ui/views/mus/text_input_client_impl.h ('K') | « ui/views/mus/window_tree_host_mus.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698