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

Unified Diff: ui/views/widget/desktop_aura/desktop_native_widget_aura.cc

Issue 1566083002: Makes sure the keyboard typing isn't blocked when InputMethod::OnFocus() is not correctly called. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remote_input_method_win.cc is gone again. Created 4 years, 11 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
« no previous file with comments | « ui/base/ime/ui_base_ime.gyp ('k') | ui/views/widget/desktop_aura/desktop_window_tree_host_win.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/widget/desktop_aura/desktop_native_widget_aura.cc
diff --git a/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc b/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc
index 618d77449607e2a0d5878b299838f0acf951d633..1e4f71f5be137818c1d0dcc217042c8a3dbdf297 100644
--- a/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc
+++ b/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc
@@ -369,8 +369,11 @@ void DesktopNativeWidgetAura::HandleActivationChanged(bool active) {
native_widget_delegate_->OnNativeWidgetActivationChanged(active);
aura::client::ActivationClient* activation_client =
aura::client::GetActivationClient(host_->window());
- if (!activation_client)
+ if (!activation_client) {
+ GetInputMethod()->GetLogCollector()->AddString(
+ "Missing OnFocus call when activating due to no activation client.");
return;
+ }
if (active) {
if (GetWidget()->HasFocusManager()) {
// This function can be called before the focus manager has had a
@@ -387,6 +390,9 @@ void DesktopNativeWidgetAura::HandleActivationChanged(bool active) {
// Refreshes the focus info to IMF in case that IMF cached the old info
// about focused text input client when it was "inactive".
GetInputMethod()->OnFocus();
+ } else {
+ GetInputMethod()->GetLogCollector()->AddString(
+ "Missing OnFocus call when activating due to no focus manager.");
}
} else {
// If we're not active we need to deactivate the corresponding
« no previous file with comments | « ui/base/ime/ui_base_ime.gyp ('k') | ui/views/widget/desktop_aura/desktop_window_tree_host_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698