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

Commit b693621b authored by Jorim Jaggi's avatar Jorim Jaggi Committed by android-build-merger
Browse files

Do not update Record.visible if not setting visibility am: e66edb10

am: f981ef57

* commit 'f981ef57':
  Do not update Record.visible if not setting visibility
parents c8dba879 f981ef57
Loading
Loading
Loading
Loading
+23 −21
Original line number Diff line number Diff line
@@ -1564,7 +1564,7 @@ final class ActivityStack {
                            resumeNextActivity = false;
                        }
                    } else {
                        makeVisible(starting, r);
                        makeVisibleIfNeeded(starting, r);
                    }
                    // Aggregate current change flags.
                    configChanges |= r.configChangeFlags;
@@ -1722,10 +1722,13 @@ final class ActivityStack {
        return behindFullscreenActivity;
    }

    private void makeVisible(ActivityRecord starting, ActivityRecord r) {
    private void makeVisibleIfNeeded(ActivityRecord starting, ActivityRecord r) {

        // This activity is not currently visible, but is running. Tell it to become visible.
        r.visible = true;
        if (r.state != ActivityState.RESUMED && r != starting) {
        if (r.state == ActivityState.RESUMED || r == starting) {
            return;
        }

        // If this activity is paused, tell it to now show its window.
        if (DEBUG_VISIBILITY) Slog.v(TAG_VISIBILITY,
                "Making visible and scheduling visibility: " + r);
@@ -1745,7 +1748,6 @@ final class ActivityStack {
            Slog.w(TAG, "Exception thrown making visibile: " + r.intent.getComponent(), e);
        }
    }
    }

    private boolean handleAlreadyVisible(ActivityRecord r) {
        if (DEBUG_VISIBILITY) Slog.v(TAG_VISIBILITY, "Skipping: already visible at " + r);