Chromium Code Reviews| 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 3cda1193d715d889eaa0a7063b20081bed50bd22..c7dee975e161a70be58bbde338cdf2b646a4b121 100644 |
| --- a/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc |
| +++ b/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc |
| @@ -384,20 +384,19 @@ void DesktopNativeWidgetAura::HandleActivationChanged(bool active) { |
| view_for_activation = GetWidget()->GetRootView(); |
| activation_client->ActivateWindow( |
| view_for_activation->GetWidget()->GetNativeView()); |
| - // 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(); |
| } |
| + // Refreshes the focus info to IMF in case that IMF cached the old info |
|
yukawa
2016/01/07 09:23:56
(optional) I'm fine with moving those logic, but c
Shu Chen
2016/01/08 02:04:11
Done.
|
| + // about focused text input client when it was "inactive". |
| + GetInputMethod()->OnFocus(); |
| } else { |
| // If we're not active we need to deactivate the corresponding |
| // aura::Window. This way if a child widget is active it gets correctly |
| // deactivated (child widgets don't get native desktop activation changes, |
| // only aura activation changes). |
| aura::Window* active_window = activation_client->GetActiveWindow(); |
| - if (active_window) { |
| + if (active_window) |
| activation_client->DeactivateWindow(active_window); |
| - GetInputMethod()->OnBlur(); |
| - } |
| + GetInputMethod()->OnBlur(); |
| } |
| } |