summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Jason Monk <jmonk@google.com> 2016-10-19 15:31:44 +0000
committer android-build-merger <android-build-merger@google.com> 2016-10-19 15:31:44 +0000
commitb4d876a5d61852892ed030e2bcb36ef0ebf6df68 (patch)
treea1343b1485a28400f1aeb5509e264af8a58a270e
parentc4ee093bf618cc73788ee07df1051054ac10b585 (diff)
parent9dce7cdf13f4e2efecd6448a1453b2fbd03959cf (diff)
Merge "Hide QS customizer correctly" am: 03e4eb32fe am: fb56958223
am: 9dce7cdf13 Change-Id: I884b10c5a187bfd4299b9ff5b6ed1aa6917c3e71
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/QSPanel.java4
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizer.java8
2 files changed, 9 insertions, 3 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java b/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
index e1db8c65c1f0..c699e275ac11 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
@@ -219,7 +219,7 @@ public class QSPanel extends LinearLayout implements Tunable, Callback {
}
public void onCollapse() {
- if (mCustomizePanel != null && mCustomizePanel.isCustomizing()) {
+ if (mCustomizePanel != null && mCustomizePanel.isShown()) {
mCustomizePanel.hide(mCustomizePanel.getWidth() / 2, mCustomizePanel.getHeight() / 2);
}
}
@@ -404,7 +404,7 @@ public class QSPanel extends LinearLayout implements Tunable, Callback {
}
public void closeDetail() {
- if (mCustomizePanel != null && mCustomizePanel.isCustomizing()) {
+ if (mCustomizePanel != null && mCustomizePanel.isShown()) {
// Treat this as a detail panel for now, to make things easy.
mCustomizePanel.hide(mCustomizePanel.getWidth() / 2, mCustomizePanel.getHeight() / 2);
return;
diff --git a/packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizer.java b/packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizer.java
index 3493d2454983..cf2c16dd8664 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizer.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizer.java
@@ -163,6 +163,10 @@ public class QSCustomizer extends LinearLayout implements OnMenuItemClickListene
}
}
+ public boolean isShown() {
+ return isShown;
+ }
+
private void setCustomizing(boolean customizing) {
mCustomizing = customizing;
mQsContainer.notifyCustomizeChanged();
@@ -217,7 +221,9 @@ public class QSCustomizer extends LinearLayout implements OnMenuItemClickListene
private final AnimatorListener mExpandAnimationListener = new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
- setCustomizing(true);
+ if (isShown) {
+ setCustomizing(true);
+ }
mNotifQsContainer.setCustomizerAnimating(false);
}