Merge "Add dumpsys info for heads up view."
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
index 4b1c888..3ee7fb2 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
@@ -2531,6 +2531,12 @@
if (mSecurityController != null) {
mSecurityController.dump(fd, pw, args);
}
+ if (mHeadsUpNotificationView != null) {
+ mHeadsUpNotificationView.dump(fd, pw, args);
+ } else {
+ pw.println(" mHeadsUpNotificationView: null");
+ }
+
pw.println("SharedPreferences:");
for (Map.Entry<String, ?> entry : mContext.getSharedPreferences(mContext.getPackageName(),
Context.MODE_PRIVATE).getAll().entrySet()) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/HeadsUpNotificationView.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/HeadsUpNotificationView.java
index 2e3e67a..2e96dd5 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/HeadsUpNotificationView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/HeadsUpNotificationView.java
@@ -44,6 +44,8 @@
import com.android.systemui.statusbar.NotificationData;
import com.android.systemui.statusbar.phone.PhoneStatusBar;
+import java.io.FileDescriptor;
+import java.io.PrintWriter;
import java.util.ArrayList;
public class HeadsUpNotificationView extends FrameLayout implements SwipeHelper.Callback, ExpandHelper.Callback,
@@ -442,6 +444,27 @@
mUser = user;
}
+ public void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
+ pw.println("HeadsUpNotificationView state:");
+ pw.print(" mTouchSensitivityDelay="); pw.println(mTouchSensitivityDelay);
+ pw.print(" mSnoozeLengthMs="); pw.println(mSnoozeLengthMs);
+ pw.print(" mMostRecentPackageName="); pw.println(mMostRecentPackageName);
+ pw.print(" mStartTouchTime="); pw.println(mStartTouchTime);
+ pw.print(" now="); pw.println(SystemClock.elapsedRealtime());
+ pw.print(" mUser="); pw.println(mUser);
+ if (mHeadsUp == null) {
+ pw.println(" mHeadsUp=null");
+ } else {
+ pw.print(" mHeadsUp="); pw.println(mHeadsUp.notification.getKey());
+ }
+ int N = mSnoozedPackages.size();
+ pw.println(" snoozed packages: " + N);
+ for (int i = 0; i < N; i++) {
+ pw.print(" "); pw.print(mSnoozedPackages.valueAt(i));
+ pw.print(", "); pw.println(mSnoozedPackages.keyAt(i));
+ }
+ }
+
private class EdgeSwipeHelper implements Gefingerpoken {
private static final boolean DEBUG_EDGE_SWIPE = false;
private final float mTouchSlop;