From f403b1fe5081aae07523043eaec8f348e1c982ea Mon Sep 17 00:00:00 2001 From: Craig Mautner Date: Tue, 19 Mar 2013 16:54:35 -0700 Subject: [PATCH] Clear mWindowAdded when window was not added. DO NOT MERGE If ViewRootImpl throws BadTokenException when adding a window, clear the indication that a window has been added. That way when the window is destroyed it doesn't try to clean it up. Fixes bug 8409506. Change-Id: I270740762f21ed4ec7f235344a3adaeaa033c483 --- core/java/android/inputmethodservice/InputMethodService.java | 1 + 1 file changed, 1 insertion(+) diff --git a/core/java/android/inputmethodservice/InputMethodService.java b/core/java/android/inputmethodservice/InputMethodService.java index 5a9cde170b709..2b15afdde9eaa 100644 --- a/core/java/android/inputmethodservice/InputMethodService.java +++ b/core/java/android/inputmethodservice/InputMethodService.java @@ -427,6 +427,7 @@ public class InputMethodService extends AbstractInputMethodService { } catch (BadTokenException e) { if (DEBUG) Log.v(TAG, "BadTokenException: IME is done."); mWindowVisible = false; + mWindowAdded = false; } } // If user uses hard keyboard, IME button should always be shown.