| Index: ui/views/ime/input_method_bridge.cc
|
| diff --git a/ui/views/ime/input_method_bridge.cc b/ui/views/ime/input_method_bridge.cc
|
| index cb7860e8eab28f1d9283b128cefdde9d1adab92a..88ceec7d5c90938ecc4a40d6ef8a880878370f25 100644
|
| --- a/ui/views/ime/input_method_bridge.cc
|
| +++ b/ui/views/ime/input_method_bridge.cc
|
| @@ -81,7 +81,8 @@ InputMethodBridge::~InputMethodBridge() {
|
| }
|
|
|
| void InputMethodBridge::OnFocus() {
|
| - DCHECK(host_);
|
| + if (!host_) // |host_| could be NULL after OnInputMethodDestroyed.
|
| + return;
|
|
|
| // Direct the shared IME to send TextInputClient messages to |this| object.
|
| if (shared_input_method_ || !host_->GetTextInputClient())
|
| @@ -96,7 +97,8 @@ void InputMethodBridge::OnFocus() {
|
| }
|
|
|
| void InputMethodBridge::OnBlur() {
|
| - DCHECK(host_);
|
| + if (!host_) // |host_| could be NULL after OnInputMethodDestroyed.
|
| + return;
|
|
|
| if (HasCompositionText()) {
|
| ConfirmCompositionText();
|
|
|