Index: ui/views/widget/native_widget_aura.cc |
diff --git a/ui/views/widget/native_widget_aura.cc b/ui/views/widget/native_widget_aura.cc |
index 851da0221ad6405e5e525e0ceec60d4aee5866e9..d13c6a06d158a45b93e1bdff3355bbf6c2571823 100644 |
--- a/ui/views/widget/native_widget_aura.cc |
+++ b/ui/views/widget/native_widget_aura.cc |
@@ -20,6 +20,7 @@ |
#include "ui/aura/window_event_dispatcher.h" |
#include "ui/aura/window_observer.h" |
#include "ui/base/dragdrop/os_exchange_data.h" |
+#include "ui/base/ui_base_switches_util.h" |
#include "ui/base/ui_base_types.h" |
#include "ui/compositor/layer.h" |
#include "ui/events/event.h" |
@@ -30,6 +31,7 @@ |
#include "ui/views/corewm/window_util.h" |
#include "ui/views/drag_utils.h" |
#include "ui/views/ime/input_method_bridge.h" |
+#include "ui/views/ime/null_input_method.h" |
#include "ui/views/views_delegate.h" |
#include "ui/views/widget/desktop_aura/desktop_native_widget_aura.h" |
#include "ui/views/widget/drop_helper.h" |
@@ -281,6 +283,10 @@ bool NativeWidgetAura::HasCapture() const { |
InputMethod* NativeWidgetAura::CreateInputMethod() { |
if (!window_) |
return NULL; |
+ |
+ if (switches::IsTextInputFocusManagerEnabled()) |
+ return new NullInputMethod(); |
+ |
aura::Window* root_window = window_->GetRootWindow(); |
ui::InputMethod* host = |
root_window->GetProperty(aura::client::kRootWindowInputMethodKey); |
@@ -291,6 +297,11 @@ internal::InputMethodDelegate* NativeWidgetAura::GetInputMethodDelegate() { |
return this; |
} |
+ui::InputMethod* NativeWidgetAura::GetHostInputMethod() { |
+ aura::Window* root_window = window_->GetRootWindow(); |
+ return root_window->GetProperty(aura::client::kRootWindowInputMethodKey); |
+} |
+ |
void NativeWidgetAura::CenterWindow(const gfx::Size& size) { |
if (!window_) |
return; |