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 5348f24b20bf077066f6cdaffd3bd32a9f8df566..4cb481bca3a58562658f20bf0f18b1e737af74f2 100644 |
--- a/ui/views/widget/native_widget_aura.cc |
+++ b/ui/views/widget/native_widget_aura.cc |
@@ -888,21 +888,9 @@ void NativeWidgetAura::OnWindowFocused(aura::Window* gained_focus, |
if (window_ == gained_focus) { |
// In aura, it is possible for child native widgets to take input and focus, |
// this differs from the behavior on windows. |
- if (GetWidget()->GetInputMethod()) // Null in tests. |
- GetWidget()->GetInputMethod()->OnFocus(); |
delegate_->OnNativeFocus(lost_focus); |
} else if (window_ == lost_focus) { |
- // GetInputMethod() recreates the input method if it's previously been |
- // destroyed. If we get called during destruction, the input method will be |
- // gone, and creating a new one and telling it that we lost the focus will |
- // trigger a DCHECK (the new input method doesn't think that we have the |
- // focus and doesn't expect a blur). OnBlur() shouldn't be called during |
- // destruction unless WIDGET_OWNS_NATIVE_WIDGET is set (which is just the |
- // case in tests). |
- if (!destroying_) { |
- if (GetWidget()->GetInputMethod()) |
- GetWidget()->GetInputMethod()->OnBlur(); |
- } else { |
+ if (destroying_) { |
sky
2013/08/26 16:01:35
nit: no {}
msw
2013/08/26 16:28:33
Done.
|
DCHECK_EQ(ownership_, Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET); |
} |