summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorTom Marshall <tdm@cyngn.com>2016-06-28 09:43:10 -0700
committerTom Marshall <tdm@cyngn.com>2016-06-28 09:46:45 -0700
commit33e91d32a7a756879649fdff13ae394229865b0b (patch)
tree56501bb0ac103211678200216730f1efdc3a9092 /services
parentc93e778562e0d662cf90c6c012f8c19766051bb0 (diff)
downloadframeworks_base-33e91d32a7a756879649fdff13ae394229865b0b.zip
frameworks_base-33e91d32a7a756879649fdff13ae394229865b0b.tar.gz
frameworks_base-33e91d32a7a756879649fdff13ae394229865b0b.tar.bz2
fw: GlobalActions: Always dismiss any existing dialog
The check for "mUiContext == null" is always false after the initial dialog is created, causing the dismiss logic to never trigger. All code uses getUiContext() now, so the check is not necessary. Remove it and re-align the create/dismiss logic with AOSP. Jira: BACON-4069 Change-Id: Ibba7b38a5fdc8410824db6d0a6f726f4a2822c9d
Diffstat (limited to 'services')
-rw-r--r--services/core/java/com/android/server/policy/GlobalActions.java5
1 files changed, 2 insertions, 3 deletions
diff --git a/services/core/java/com/android/server/policy/GlobalActions.java b/services/core/java/com/android/server/policy/GlobalActions.java
index 34fc905..96e1c70 100644
--- a/services/core/java/com/android/server/policy/GlobalActions.java
+++ b/services/core/java/com/android/server/policy/GlobalActions.java
@@ -248,14 +248,12 @@ class GlobalActions implements DialogInterface.OnDismissListener, DialogInterfac
public void showDialog(boolean keyguardShowing, boolean isDeviceProvisioned) {
mKeyguardShowing = keyguardShowing;
mDeviceProvisioned = isDeviceProvisioned;
- if (mDialog != null && mUiContext == null) {
+ if (mDialog != null) {
mDialog.dismiss();
mDialog = null;
- mDialog = createDialog();
// Show delayed, so that the dismiss of the previous dialog completes
mHandler.sendEmptyMessage(MESSAGE_SHOW);
} else {
- mDialog = createDialog();
handleShow();
}
}
@@ -274,6 +272,7 @@ class GlobalActions implements DialogInterface.OnDismissListener, DialogInterfac
private void handleShow() {
awakenIfNecessary();
+ mDialog = createDialog();
prepareDialog();
// If we only have 1 item and it's a simple press action, just do this action.