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

Commit b194837f authored by Jerry Chang's avatar Jerry Chang
Browse files

Fix dismissing wrong stage when droping divider to the edge

Fix: 181143181
Test: manual check
Test: atest WMShellUnitTests
Change-Id: I273594fe25d4b4efe060180b876446ebc1daede8
parent 52e885a6
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -362,8 +362,9 @@ class StageCoordinator implements SplitLayout.LayoutChangeListener,

    @Override
    public void onSnappedToDismiss(boolean bottomOrRight) {
        final boolean mainStageToTop = bottomOrRight
                && mSideStagePosition == STAGE_POSITION_BOTTOM_OR_RIGHT;
        final boolean mainStageToTop =
                bottomOrRight ? mSideStagePosition == STAGE_POSITION_BOTTOM_OR_RIGHT
                        : mSideStagePosition == STAGE_POSITION_TOP_OR_LEFT;
        exitSplitScreen(mainStageToTop ? mMainStage : mSideStage);
    }