From 7a489fdbac672a375dd381f539f08d71f8b79596 Mon Sep 17 00:00:00 2001 From: Dianne Hackborn <> Date: Fri, 27 Mar 2009 18:51:15 -0700 Subject: [PATCH] AI 143413: Fix issue #1742588 (Crash phone while switching between keyboard settings and Gmail) BUG=1742588 Automated import of CL 143413 --- .../android/internal/policy/impl/PhoneWindowManager.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/policy/com/android/internal/policy/impl/PhoneWindowManager.java b/policy/com/android/internal/policy/impl/PhoneWindowManager.java index bf0f81518c115..cc0588d9dda9b 100644 --- a/policy/com/android/internal/policy/impl/PhoneWindowManager.java +++ b/policy/com/android/internal/policy/impl/PhoneWindowManager.java @@ -245,6 +245,7 @@ public class PhoneWindowManager implements WindowManagerPolicy { public void update() { ContentResolver resolver = mContext.getContentResolver(); + boolean updateRotation = false; synchronized (mLock) { mEndcallBehavior = Settings.System.getInt(resolver, Settings.System.END_BUTTON_BEHAVIOR, DEFAULT_ENDCALL_BEHAVIOR); @@ -261,9 +262,12 @@ public class PhoneWindowManager implements WindowManagerPolicy { boolean hasSoftInput = imId != null && imId.length() > 0; if (mHasSoftInput != hasSoftInput) { mHasSoftInput = hasSoftInput; - updateRotation(0); + updateRotation = true; } } + if (updateRotation) { + updateRotation(0); + } } }