summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2009-12-03 11:37:44 -0800
committerDianne Hackborn <hackbod@google.com>2009-12-03 11:37:44 -0800
commit4dbf514c6c73832630e4c9bb068cf950ff044a34 (patch)
tree5cdb26a41f504b1a4d9c0631f6294a2c0545858e
parentdb0ec6480b806799f05f3d6fd04d742564af8f2f (diff)
downloadbase-4dbf514c6c73832630e4c9bb068cf950ff044a34.tar.gz
Fix issue #2302336: System dialogs are not being given a layerandroid-sdk-2.1_r1android-2.1_r1
Define a new dedicated layer for system dialogs and use it. Change-Id: Iaa8b7a48617ae37ea3e83c9f77b1d357f750f5bc
-rwxr-xr-xphone/com/android/internal/policy/impl/PhoneWindowManager.java25
1 files changed, 14 insertions, 11 deletions
diff --git a/phone/com/android/internal/policy/impl/PhoneWindowManager.java b/phone/com/android/internal/policy/impl/PhoneWindowManager.java
index feb0717..27a42bc 100755
--- a/phone/com/android/internal/policy/impl/PhoneWindowManager.java
+++ b/phone/com/android/internal/policy/impl/PhoneWindowManager.java
@@ -85,6 +85,7 @@ import static android.view.WindowManager.LayoutParams.TYPE_PRIORITY_PHONE;
import static android.view.WindowManager.LayoutParams.TYPE_SEARCH_BAR;
import static android.view.WindowManager.LayoutParams.TYPE_STATUS_BAR;
import static android.view.WindowManager.LayoutParams.TYPE_STATUS_BAR_PANEL;
+import static android.view.WindowManager.LayoutParams.TYPE_SYSTEM_DIALOG;
import static android.view.WindowManager.LayoutParams.TYPE_SYSTEM_ALERT;
import static android.view.WindowManager.LayoutParams.TYPE_SYSTEM_ERROR;
import static android.view.WindowManager.LayoutParams.TYPE_INPUT_METHOD;
@@ -94,7 +95,6 @@ import static android.view.WindowManager.LayoutParams.TYPE_TOAST;
import static android.view.WindowManager.LayoutParams.TYPE_WALLPAPER;
import android.view.WindowManagerImpl;
import android.view.WindowManagerPolicy;
-import android.view.WindowManagerPolicy.WindowState;
import android.view.animation.Animation;
import android.view.animation.AnimationUtils;
import android.media.IAudioService;
@@ -121,25 +121,26 @@ public class PhoneWindowManager implements WindowManagerPolicy {
static final int PHONE_LAYER = 3;
static final int SEARCH_BAR_LAYER = 4;
static final int STATUS_BAR_PANEL_LAYER = 5;
+ static final int SYSTEM_DIALOG_LAYER = 6;
// toasts and the plugged-in battery thing
- static final int TOAST_LAYER = 6;
- static final int STATUS_BAR_LAYER = 7;
+ static final int TOAST_LAYER = 7;
+ static final int STATUS_BAR_LAYER = 8;
// SIM errors and unlock. Not sure if this really should be in a high layer.
- static final int PRIORITY_PHONE_LAYER = 8;
+ static final int PRIORITY_PHONE_LAYER = 9;
// like the ANR / app crashed dialogs
- static final int SYSTEM_ALERT_LAYER = 9;
+ static final int SYSTEM_ALERT_LAYER = 10;
// system-level error dialogs
- static final int SYSTEM_ERROR_LAYER = 10;
+ static final int SYSTEM_ERROR_LAYER = 11;
// on-screen keyboards and other such input method user interfaces go here.
- static final int INPUT_METHOD_LAYER = 11;
+ static final int INPUT_METHOD_LAYER = 12;
// on-screen keyboards and other such input method user interfaces go here.
- static final int INPUT_METHOD_DIALOG_LAYER = 12;
+ static final int INPUT_METHOD_DIALOG_LAYER = 13;
// the keyguard; nothing on top of these can take focus, since they are
// responsible for power management when displayed.
- static final int KEYGUARD_LAYER = 13;
- static final int KEYGUARD_DIALOG_LAYER = 14;
+ static final int KEYGUARD_LAYER = 14;
+ static final int KEYGUARD_DIALOG_LAYER = 15;
// things in here CAN NOT take focus, but are shown on top of everything else.
- static final int SYSTEM_OVERLAY_LAYER = 15;
+ static final int SYSTEM_OVERLAY_LAYER = 16;
static final int APPLICATION_MEDIA_SUBLAYER = -2;
static final int APPLICATION_MEDIA_OVERLAY_SUBLAYER = -1;
@@ -687,6 +688,8 @@ public class PhoneWindowManager implements WindowManagerPolicy {
return STATUS_BAR_LAYER;
case TYPE_STATUS_BAR_PANEL:
return STATUS_BAR_PANEL_LAYER;
+ case TYPE_SYSTEM_DIALOG:
+ return SYSTEM_DIALOG_LAYER;
case TYPE_SEARCH_BAR:
return SEARCH_BAR_LAYER;
case TYPE_PHONE: