summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorSuchi Amalapurapu <asuchitra@google.com>2009-10-28 14:32:05 -0700
committerSuchi Amalapurapu <asuchitra@google.com>2009-10-28 14:47:45 -0700
commitc03d28b9e96f667d29ec6e480bed171bbd07169d (patch)
tree7c26474e03aa9c1240c181702768208af8f8fff9 /services
parent763ccae7d734cc7e55772936dc3f101a2bf453d4 (diff)
downloadframeworks_base-c03d28b9e96f667d29ec6e480bed171bbd07169d.zip
frameworks_base-c03d28b9e96f667d29ec6e480bed171bbd07169d.tar.gz
frameworks_base-c03d28b9e96f667d29ec6e480bed171bbd07169d.tar.bz2
Check that the window which wants to force hide is visible before setting the flag forceHiding to true. If we do layout the surfaces
again this flag gets set no matter what since the keyguard window is always present in the list of tokens and this hides the window which would have become visible since the keyguard just got dismissed. This causes unnecessary focus changes due to changes in visibility of current window. This will resolve issues related to current focus and time outs when dispatching key events.
Diffstat (limited to 'services')
-rw-r--r--services/java/com/android/server/WindowManagerService.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/services/java/com/android/server/WindowManagerService.java b/services/java/com/android/server/WindowManagerService.java
index 6418901..94667eb 100644
--- a/services/java/com/android/server/WindowManagerService.java
+++ b/services/java/com/android/server/WindowManagerService.java
@@ -9653,7 +9653,8 @@ public class WindowManagerService extends IWindowManager.Stub
WindowState w = (WindowState)mWindows.get(i);
if (w.mSurface != null) {
final WindowManager.LayoutParams attrs = w.mAttrs;
- if (mPolicy.doesForceHide(w, attrs)) {
+ if (mPolicy.doesForceHide(w, attrs) && w.isVisibleLw()) {
+ if (DEBUG_FOCUS) Log.i(TAG, "win=" + w + " force hides other windows");
forceHiding = true;
} else if (mPolicy.canBeForceHidden(w, attrs)) {
if (!w.mAnimating) {