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

Commit 60191494 authored by Liran Binyamin's avatar Liran Binyamin
Browse files

AIDL method to move bubble to fullscreen

This will be used from launcher to move a bubble to full screen.

Flag: com.android.wm.shell.enable_bubble_to_fullscreen
Test: this is not wired up, so just tested that it builds
Bug: 393173014
Change-Id: I41e6eb6c0845746be9b189e250c8623588fa798d
parent 6e63524c
Loading
Loading
Loading
Loading
+14 −0
Original line number Diff line number Diff line
@@ -2643,6 +2643,15 @@ public class BubbleController implements ConfigurationChangeListener,
        mBubbleData.setSelectedBubbleAndExpandStack(bubbleToSelect);
    }

    private void moveBubbleToFullscreen(String key) {
        Bubble b = mBubbleData.getBubbleInStackWithKey(key);
        if (b == null) {
            Log.w(TAG, "can't find bubble with key " + key + " to move to fullscreen");
            return;
        }
        b.getTaskView().moveToFullscreen();
    }

    private boolean isDeviceLocked() {
        return !mIsStatusBarShade;
    }
@@ -2929,6 +2938,11 @@ public class BubbleController implements ConfigurationChangeListener,
                }
            });
        }

        @Override
        public void moveBubbleToFullscreen(String key) {
            mMainExecutor.execute(() -> mController.moveBubbleToFullscreen(key));
        }
    }

    private class BubblesImpl implements Bubbles {
+0 −1
Original line number Diff line number Diff line
@@ -1236,7 +1236,6 @@ public class BubbleData {

    /** @return the bubble in the stack that matches the provided key. */
    @Nullable
    @VisibleForTesting(visibility = PRIVATE)
    public Bubble getBubbleInStackWithKey(String key) {
        return getBubbleWithPredicate(mBubbles, b -> b.getKey().equals(key));
    }
+2 −0
Original line number Diff line number Diff line
@@ -58,4 +58,6 @@ interface IBubbles {
    oneway void showExpandedView() = 14;

    oneway void showDropTarget(in boolean show, in @nullable BubbleBarLocation location) = 15;

    oneway void moveBubbleToFullscreen(in String key) = 16;
}
 No newline at end of file