Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 73dec3eb authored by Ats Jenk's avatar Ats Jenk
Browse files

Remove pattern matching instanceof

Protolog tool does not handle pattern matching.

Bug: 349845968
Change-Id: I2c9324134803d61f28574d17497ec53ccb41943b
Test: m
Flag: com.android.wm.shell.enable_bubble_bar
parent 08f37916
Loading
Loading
Loading
Loading
+6 −4
Original line number Diff line number Diff line
@@ -2087,8 +2087,9 @@ public class BubbleController implements ConfigurationChangeListener,

            BubbleLogger.Event event = isExpanded ? BubbleLogger.Event.BUBBLE_BAR_EXPANDED
                    : BubbleLogger.Event.BUBBLE_BAR_COLLAPSED;
            if (mBubbleData.getSelectedBubble() instanceof Bubble bubble) {
                mLogger.log(bubble, event);
            BubbleViewProvider selectedBubble = mBubbleData.getSelectedBubble();
            if (selectedBubble instanceof Bubble) {
                mLogger.log((Bubble) selectedBubble, event);
            } else {
                mLogger.log(event);
            }
@@ -2099,8 +2100,9 @@ public class BubbleController implements ConfigurationChangeListener,
            // Only need to update the layer view if we're currently expanded for selection changes.
            if (mLayerView != null && mLayerView.isExpanded()) {
                mLayerView.showExpandedView(selectedBubble);
                if (selectedBubble instanceof Bubble bubble) {
                    mLogger.log(bubble, BubbleLogger.Event.BUBBLE_BAR_BUBBLE_SWITCHED);
                if (selectedBubble instanceof Bubble) {
                    mLogger.log((Bubble) selectedBubble,
                            BubbleLogger.Event.BUBBLE_BAR_BUBBLE_SWITCHED);
                }
            }
        }