Use bubble count for checking if bubble bar has bubbles
hasBubbles() was checking if there is a selected bubble. If there was one, it returned true.
Update it to return true when bubble bar has bubble views.
This aligns it with the name of the method and the javadoc.
Bug: 385928447
Change-Id: If3dafb7608f71b8600dbac064b08a7f7114a361f
Test: check that bubble bar is tappable
Test: check that bubble bar is shown next to QSB on foldable
Test: check bubble bar position with 3 button nav
Flag: com.android.wm.shell.enable_bubble_bar
diff --git a/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleBarViewController.java b/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleBarViewController.java
index 5685093..84243f5 100644
--- a/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleBarViewController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleBarViewController.java
@@ -481,7 +481,7 @@
/** Whether the bubble bar has bubbles. */
public boolean hasBubbles() {
- return mBubbleBarController.getSelectedBubbleKey() != null;
+ return mBarView.getBubbleChildCount() > 0;
}
/**