summaryrefslogtreecommitdiffstats
path: root/services/core
diff options
context:
space:
mode:
authorSeigo Nonaka <nona@google.com>2015-06-17 16:04:43 +0900
committerSeigo Nonaka <nona@google.com>2015-06-18 12:22:36 +0900
commitd56ec1d44479cac0820c6afe9aaa689fc47c431d (patch)
treea92d62b9d6cef21d1a005536b151fd28cde97d6f /services/core
parentc73cd407f0e886e5d0b26dda6b82d88ac9eec36a (diff)
downloadframeworks_base-d56ec1d44479cac0820c6afe9aaa689fc47c431d.zip
frameworks_base-d56ec1d44479cac0820c6afe9aaa689fc47c431d.tar.gz
frameworks_base-d56ec1d44479cac0820c6afe9aaa689fc47c431d.tar.bz2
Fix IME window flickering during rotation.
This was introduced by Ifd15736b163ab, performLayoutAndPlaceSurfacesLocked is called even if computeNewConfigurationLocked() returns non-null object. This is simply by mistake and now computeNewConfigurationLocked never returns null. The only case we need to care is that mDisplayReady is false, but there is nothing to do with that state. Thus simply removes if segments from computeNewConfiguration. Bug: 20823978 Change-Id: I527dfeddffb8d928d578f8d60d64f98557aa3dcb
Diffstat (limited to 'services/core')
-rw-r--r--services/core/java/com/android/server/wm/WindowManagerService.java18
1 files changed, 6 insertions, 12 deletions
diff --git a/services/core/java/com/android/server/wm/WindowManagerService.java b/services/core/java/com/android/server/wm/WindowManagerService.java
index 1b63ca0..ace5997 100644
--- a/services/core/java/com/android/server/wm/WindowManagerService.java
+++ b/services/core/java/com/android/server/wm/WindowManagerService.java
@@ -7139,20 +7139,14 @@ public class WindowManagerService extends IWindowManager.Stub
public Configuration computeNewConfiguration() {
synchronized (mWindowMap) {
- if (!mDisplayReady) {
- return null;
- }
- Configuration config = computeNewConfigurationLocked();
- if (mWaitingForConfig) {
- mWaitingForConfig = false;
- mLastFinishedFreezeSource = "new-config";
- performLayoutAndPlaceSurfacesLocked();
- }
- return config;
+ return computeNewConfigurationLocked();
}
}
- Configuration computeNewConfigurationLocked() {
+ private Configuration computeNewConfigurationLocked() {
+ if (!mDisplayReady) {
+ return null;
+ }
Configuration config = new Configuration();
config.fontScale = 0;
computeScreenConfigurationLocked(config);
@@ -9678,7 +9672,7 @@ public class WindowManagerService extends IWindowManager.Stub
/**
* Extracted from {@link #performLayoutAndPlaceSurfacesLockedInner} to reduce size of method.
- * @param w WindowState this method is applied to.
+ * @param w WindowState this method is applied to.
* @param innerDw Width of app window.
* @param innerDh Height of app window.
*/