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

Commit 7f2f6be0 authored by Winson Chung's avatar Winson Chung
Browse files

Extract BubbleTransitions for use by DefaultMixedHandler

- We need to handle bubble transitions that are core-initiated as
  well as shell initiated

Bug: 396313972
Flag: EXEMPT bugfix
Test: atest ActivityOptionsTest
Change-Id: I3bb19ffcccc67037568ba36b0de4f3535cc195f7
parent 1878c40c
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -268,6 +268,7 @@ class BubbleControllerBubbleBarTest {
            surfaceSynchronizer,
            FloatingContentCoordinator(),
            bubbleDataRepository,
            mock<BubbleTransitions>(),
            mock<IStatusBarService>(),
            mock<WindowManager>(),
            mock<DisplayInsetsController>(),
+1 −0
Original line number Diff line number Diff line
@@ -368,6 +368,7 @@ class BubbleControllerTest(flags: FlagsParameterization) {
                surfaceSynchronizer,
                FloatingContentCoordinator(),
                bubbleDataRepository,
                mock<BubbleTransitions>(),
                mock<IStatusBarService>(),
                windowManager,
                displayInsetsController,
+1 −0
Original line number Diff line number Diff line
@@ -141,6 +141,7 @@ class BubbleViewInfoTaskTest {
                surfaceSynchronizer,
                FloatingContentCoordinator(),
                bubbleDataRepository,
                mock<BubbleTransitions>(),
                mock<IStatusBarService>(),
                windowManager,
                mock<DisplayInsetsController>(),
+2 −0
Original line number Diff line number Diff line
@@ -50,6 +50,7 @@ import com.android.wm.shell.bubbles.BubbleExpandedViewManager
import com.android.wm.shell.bubbles.BubbleLogger
import com.android.wm.shell.bubbles.BubblePositioner
import com.android.wm.shell.bubbles.BubbleResizabilityChecker
import com.android.wm.shell.bubbles.BubbleTransitions
import com.android.wm.shell.bubbles.Bubbles.SysuiProxy
import com.android.wm.shell.bubbles.FakeBubbleExpandedViewManager
import com.android.wm.shell.bubbles.FakeBubbleFactory
@@ -212,6 +213,7 @@ class BubbleBarLayerViewTest {
            surfaceSynchronizer,
            FloatingContentCoordinator(),
            bubbleDataRepository,
            mock<BubbleTransitions>(),
            mock<IStatusBarService>(),
            windowManager,
            mock<DisplayInsetsController>(),
+3 −3
Original line number Diff line number Diff line
@@ -310,6 +310,7 @@ public class BubbleController implements ConfigurationChangeListener,
            @Nullable BubbleStackView.SurfaceSynchronizer synchronizer,
            FloatingContentCoordinator floatingContentCoordinator,
            BubbleDataRepository dataRepository,
            BubbleTransitions bubbleTransitions,
            @Nullable IStatusBarService statusBarService,
            WindowManager windowManager,
            DisplayInsetsController displayInsetsController,
@@ -374,14 +375,12 @@ public class BubbleController implements ConfigurationChangeListener,
            tvTransitions = taskViewTransitions;
        }
        mTaskViewController = new BubbleTaskViewController(tvTransitions);
        mBubbleTransitions = new BubbleTransitions(transitions, organizer, taskViewRepository, data,
                tvTransitions, context);
        mTransitions = transitions;
        mOneHandedOptional = oneHandedOptional;
        mDragAndDropController = dragAndDropController;
        mSyncQueue = syncQueue;
        mWmService = wmService;
        shellInit.addInitCallback(this::onInit, this);
        mBubbleTransitions = bubbleTransitions;
        mBubbleTaskViewFactory = new BubbleTaskViewFactory() {
            @Override
            public BubbleTaskView create() {
@@ -395,6 +394,7 @@ public class BubbleController implements ConfigurationChangeListener,
        mExpandedViewManager = BubbleExpandedViewManager.fromBubbleController(this);
        mResizabilityChecker = resizabilityChecker;
        mHomeIntentProvider = homeIntentProvider;
        shellInit.addInitCallback(this::onInit, this);
    }

    private void registerOneHandedState(OneHandedController oneHanded) {
Loading