diff options
6 files changed, 34 insertions, 22 deletions
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/Bubble.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/Bubble.java index 9a2b81243861..85ea8097a2c1 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/Bubble.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/Bubble.java @@ -973,9 +973,9 @@ public class Bubble implements BubbleViewProvider { pw.print(" suppressNotif: "); pw.println(shouldSuppressNotification()); pw.print(" autoExpand: "); pw.println(shouldAutoExpand()); pw.print(" isDismissable: "); pw.println(mIsDismissable); - pw.println(" bubbleMetadataFlagListener null: " + (mBubbleMetadataFlagListener == null)); + pw.println(" bubbleMetadataFlagListener null?: " + (mBubbleMetadataFlagListener == null)); if (mExpandedView != null) { - mExpandedView.dump(pw); + mExpandedView.dump(pw, " "); } } diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java index 645a96153080..dfdc79ea7afa 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java @@ -1991,13 +1991,20 @@ public class BubbleController implements ConfigurationChangeListener, * Description of current bubble state. */ private void dump(PrintWriter pw, String prefix) { - pw.println("BubbleController state:"); + pw.print(prefix); pw.println("BubbleController state:"); + pw.print(prefix); pw.println(" currentUserId= " + mCurrentUserId); + pw.print(prefix); pw.println(" isStatusBarShade= " + mIsStatusBarShade); + pw.print(prefix); pw.println(" isShowingAsBubbleBar= " + isShowingAsBubbleBar()); + pw.println(); + mBubbleData.dump(pw); pw.println(); + if (mStackView != null) { mStackView.dump(pw); } pw.println(); + mImpl.mCachedState.dump(pw); } @@ -2246,8 +2253,7 @@ public class BubbleController implements ConfigurationChangeListener, pw.println("mIsStackExpanded: " + mIsStackExpanded); pw.println("mSelectedBubbleKey: " + mSelectedBubbleKey); - pw.print("mSuppressedBubbleKeys: "); - pw.println(mSuppressedBubbleKeys.size()); + pw.println("mSuppressedBubbleKeys: " + mSuppressedBubbleKeys.size()); for (String key : mSuppressedBubbleKeys) { pw.println(" suppressing: " + key); } diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleData.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleData.java index cc8f50e09fcb..c6f74af0284b 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleData.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleData.java @@ -1231,29 +1231,30 @@ public class BubbleData { * Description of current bubble data state. */ public void dump(PrintWriter pw) { - pw.print("selected: "); + pw.println("BubbleData state:"); + pw.print(" selected: "); pw.println(mSelectedBubble != null ? mSelectedBubble.getKey() : "null"); - pw.print("expanded: "); + pw.print(" expanded: "); pw.println(mExpanded); - pw.print("stack bubble count: "); + pw.print("Stack bubble count: "); pw.println(mBubbles.size()); for (Bubble bubble : mBubbles) { bubble.dump(pw); } - pw.print("overflow bubble count: "); + pw.print("Overflow bubble count: "); pw.println(mOverflowBubbles.size()); for (Bubble bubble : mOverflowBubbles) { bubble.dump(pw); } - pw.print("summaryKeys: "); + pw.print("SummaryKeys: "); pw.println(mSuppressedGroupKeys.size()); for (String key : mSuppressedGroupKeys.keySet()) { - pw.println(" suppressing: " + key); + pw.println(" suppressing: " + key); } } } diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleDebugConfig.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleDebugConfig.java index 76662c47238f..1c0e0522d359 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleDebugConfig.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleDebugConfig.java @@ -77,20 +77,25 @@ public class BubbleDebugConfig { static String formatBubblesString(List<Bubble> bubbles, BubbleViewProvider selected) { StringBuilder sb = new StringBuilder(); - for (Bubble bubble : bubbles) { + for (int i = 0; i < bubbles.size(); i++) { + Bubble bubble = bubbles.get(i); if (bubble == null) { - sb.append(" <null> !!!!!\n"); + sb.append(" <null> !!!!!"); } else { boolean isSelected = (selected != null - && selected.getKey() != BubbleOverflow.KEY + && !BubbleOverflow.KEY.equals(selected.getKey()) && bubble == selected); String arrow = isSelected ? "=>" : " "; - sb.append(String.format("%s Bubble{act=%12d, showInShade=%d, key=%s}\n", + + sb.append(String.format("%s Bubble{act=%12d, showInShade=%d, key=%s}", arrow, bubble.getLastActivity(), (bubble.showInShade() ? 1 : 0), bubble.getKey())); } + if (i != bubbles.size() - 1) { + sb.append("\n"); + } } return sb.toString(); } diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleExpandedView.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleExpandedView.java index e6986012dd88..37bcf1ddeac5 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleExpandedView.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleExpandedView.java @@ -1094,9 +1094,9 @@ public class BubbleExpandedView extends LinearLayout { /** * Description of current expanded view state. */ - public void dump(@NonNull PrintWriter pw) { - pw.print("BubbleExpandedView"); - pw.print(" taskId: "); pw.println(mTaskId); - pw.print(" stackView: "); pw.println(mStackView); + public void dump(@NonNull PrintWriter pw, @NonNull String prefix) { + pw.print(prefix); pw.println("BubbleExpandedView:"); + pw.print(prefix); pw.print(" taskId: "); pw.println(mTaskId); + pw.print(prefix); pw.print(" stackView: "); pw.println(mStackView); } } diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java index 52c9bf8462ec..093ecb1e3ade 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java @@ -305,8 +305,7 @@ public class BubbleStackView extends FrameLayout String bubblesOnScreen = BubbleDebugConfig.formatBubblesString( getBubblesOnScreen(), getExpandedBubble()); - pw.print(" stack visibility : "); pw.println(getVisibility()); - pw.print(" bubbles on screen: "); pw.println(bubblesOnScreen); + pw.println(" bubbles on screen: "); pw.println(bubblesOnScreen); pw.print(" gestureInProgress: "); pw.println(mIsGestureInProgress); pw.print(" showingDismiss: "); pw.println(mDismissView.isShowing()); pw.print(" isExpansionAnimating: "); pw.println(mIsExpansionAnimating); @@ -314,7 +313,8 @@ public class BubbleStackView extends FrameLayout pw.print(" expandedContainerAlpha: "); pw.println(mExpandedViewContainer.getAlpha()); pw.print(" expandedContainerMatrix: "); pw.println(mExpandedViewContainer.getAnimationMatrix()); - + pw.print(" stack visibility : "); pw.println(getVisibility()); + pw.print(" temporarilyInvisible: "); pw.println(mTemporarilyInvisible); mStackAnimationController.dump(pw); mExpandedAnimationController.dump(pw); |