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

Commit 2c490fdf authored by Wei Sheng Shih's avatar Wei Sheng Shih Committed by Android (Google) Code Review
Browse files

Merge "Remove flag ensure_starting_window_remove_from_task" into main

parents c4655419 9108e121
Loading
Loading
Loading
Loading
+0 −11
Original line number Diff line number Diff line
@@ -403,17 +403,6 @@ flag {
    bug: "424146227"
}

flag {
    name: "ensure_starting_window_remove_from_task"
    namespace: "windowing_frontend"
    description: "Trigger the removal of the starting window from the task in case the shared starting data is not attached to itself."
    bug: "405253899"
    is_fixed_read_only: true
    metadata {
        purpose: PURPOSE_BUGFIX
    }
}

flag {
    name: "polish_close_wallpaper_includes_open_change"
    namespace: "windowing_frontend"
+4 −15
Original line number Diff line number Diff line
@@ -5410,8 +5410,7 @@ final class ActivityRecord extends WindowToken {
                    && mDisplayContent.mInputMethodWindow != null
                    && mDisplayContent.mInputMethodWindow.isVisible();
            finishOrAbortReplacingWindow();
            if (Flags.ensureStartingWindowRemoveFromTask() && !firstWindowDrawn && task != null
                    && task.mSharedStartingData != null) {
            if (!firstWindowDrawn && task != null && task.mSharedStartingData != null) {
                final ActivityRecord r = getSharedStartingWindowOwnerIfTaskDrawn();
                if (r != null) {
                    r.removeStartingWindow();
@@ -6533,20 +6532,10 @@ final class ActivityRecord extends WindowToken {
        if (associatedTask == null) {
            removeStartingWindow();
        } else {
            if (Flags.ensureStartingWindowRemoveFromTask()) {
            final ActivityRecord r = getSharedStartingWindowOwnerIfTaskDrawn();
            if (r != null) {
                r.removeStartingWindow();
            }
            } else if (associatedTask.getActivity(
                    r -> r.isVisibleRequested() && !r.firstWindowDrawn) == null) {
                // The last drawn activity may not be the one that owns the starting window.
                final ActivityRecord r = associatedTask.getActivity(
                        ar -> ar.mStartingData != null);
                if (r != null) {
                    r.removeStartingWindow();
                }
            }
        }
        updateReportedVisibilityLocked();
    }
+0 −1
Original line number Diff line number Diff line
@@ -3168,7 +3168,6 @@ public class ActivityRecordTests extends WindowTestsBase {
    }

    @Test
    @EnableFlags(Flags.FLAG_ENSURE_STARTING_WINDOW_REMOVE_FROM_TASK)
    public void testStartingWindowInTaskFragment_RemoveAfterTrampolineInvisible() {
        testStartingWindowInTaskFragment_RemoveFrom(false, true);
    }