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

Unified Diff: ui/views/view.cc

Issue 23245012: Fix Views Combobox and Tree View text input. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Move InputMethod focus/blur to View. Created 7 years, 4 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
« ui/views/controls/tree/tree_view.cc ('K') | « ui/views/controls/tree/tree_view.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/view.cc
diff --git a/ui/views/view.cc b/ui/views/view.cc
index 73b1e4ef2f2d39d7a6ae94fe98f7e566a12e75d2..57f4d5a6a1b197f39378f8a672ff76ea0e203d73 100644
--- a/ui/views/view.cc
+++ b/ui/views/view.cc
@@ -37,6 +37,7 @@
#include "ui/views/background.h"
#include "ui/views/context_menu_controller.h"
#include "ui/views/drag_controller.h"
+#include "ui/views/ime/input_method.h"
#include "ui/views/layout/layout_manager.h"
#include "ui/views/views_delegate.h"
#include "ui/views/widget/native_widget_private.h"
@@ -1543,6 +1544,9 @@ void View::OnFocus() {
if (focus_manager)
focus_manager->ClearNativeFocus();
+ if (GetInputMethod())
+ GetInputMethod()->OnFocus();
+
// TODO(beng): Investigate whether it's possible for us to move this to
// Focus().
// Notify assistive technologies of the focus change.
@@ -1550,6 +1554,8 @@ void View::OnFocus() {
}
void View::OnBlur() {
+ if (GetInputMethod())
+ GetInputMethod()->OnBlur();
}
void View::Focus() {
« ui/views/controls/tree/tree_view.cc ('K') | « ui/views/controls/tree/tree_view.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698