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

Commit 652a4815 authored by Chavi Weingarten's avatar Chavi Weingarten Committed by Android (Google) Code Review
Browse files

Merge "Added getSyncTransaction" into rvc-dev

parents a7e99b00 89cc30e9
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -5985,9 +5985,9 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A


        if (mSurfaceControl != null) {
        if (mSurfaceControl != null) {
            if (show && !mLastSurfaceShowing) {
            if (show && !mLastSurfaceShowing) {
                getPendingTransaction().show(mSurfaceControl);
                getSyncTransaction().show(mSurfaceControl);
            } else if (!show && mLastSurfaceShowing) {
            } else if (!show && mLastSurfaceShowing) {
                getPendingTransaction().hide(mSurfaceControl);
                getSyncTransaction().hide(mSurfaceControl);
            }
            }
        }
        }
        if (mThumbnail != null) {
        if (mThumbnail != null) {
+1 −1
Original line number Original line Diff line number Diff line
@@ -3213,7 +3213,7 @@ class ActivityStack extends Task {
    }
    }


    private void updateSurfaceBounds() {
    private void updateSurfaceBounds() {
        updateSurfaceSize(getPendingTransaction());
        updateSurfaceSize(getSyncTransaction());
        updateSurfacePosition();
        updateSurfacePosition();
        scheduleAnimation();
        scheduleAnimation();
    }
    }
+1 −1
Original line number Original line Diff line number Diff line
@@ -53,7 +53,7 @@ class Dimmer {


        @Override
        @Override
        public SurfaceControl.Transaction getPendingTransaction() {
        public SurfaceControl.Transaction getPendingTransaction() {
            return mHost.getPendingTransaction();
            return mHost.getSyncTransaction();
        }
        }


        @Override
        @Override
+1 −1
Original line number Original line Diff line number Diff line
@@ -290,7 +290,7 @@ public class DisplayArea<T extends WindowContainer> extends WindowContainer<T> {
                mDimmer.resetDimStates();
                mDimmer.resetDimStates();
            }
            }


            if (mDimmer.updateDims(getPendingTransaction(), mTmpDimBoundsRect)) {
            if (mDimmer.updateDims(getSyncTransaction(), mTmpDimBoundsRect)) {
                scheduleAnimation();
                scheduleAnimation();
            }
            }
        }
        }
+5 −19
Original line number Original line Diff line number Diff line
@@ -1923,7 +1923,7 @@ class Task extends WindowContainer<WindowContainer> {
        super.onConfigurationChanged(newParentConfig);
        super.onConfigurationChanged(newParentConfig);
        // Only need to update surface size here since the super method will handle updating
        // Only need to update surface size here since the super method will handle updating
        // surface position.
        // surface position.
        updateSurfaceSize(getPendingTransaction());
        updateSurfaceSize(getSyncTransaction());


        if (wasInPictureInPicture != inPinnedWindowingMode()) {
        if (wasInPictureInPicture != inPinnedWindowingMode()) {
            mStackSupervisor.scheduleUpdatePictureInPictureModeIfNeeded(this, getStack());
            mStackSupervisor.scheduleUpdatePictureInPictureModeIfNeeded(this, getStack());
@@ -3475,20 +3475,6 @@ class Task extends WindowContainer<WindowContainer> {
        return mDimmer;
        return mDimmer;
    }
    }


    void dim(float alpha) {
        mDimmer.dimAbove(getPendingTransaction(), alpha);
        scheduleAnimation();
    }

    void stopDimming() {
        mDimmer.stopDim(getPendingTransaction());
        scheduleAnimation();
    }

    boolean isTaskForUser(int userId) {
        return mUserId == userId;
    }

    @Override
    @Override
    void prepareSurfaces() {
    void prepareSurfaces() {
        mDimmer.resetDimStates();
        mDimmer.resetDimStates();
@@ -3504,9 +3490,9 @@ class Task extends WindowContainer<WindowContainer> {
            mTmpDimBoundsRect.offsetTo(0, 0);
            mTmpDimBoundsRect.offsetTo(0, 0);
        }
        }


        updateShadowsRadius(isFocused(), getPendingTransaction());
        updateShadowsRadius(isFocused(), getSyncTransaction());


        if (mDimmer.updateDims(getPendingTransaction(), mTmpDimBoundsRect)) {
        if (mDimmer.updateDims(getSyncTransaction(), mTmpDimBoundsRect)) {
            scheduleAnimation();
            scheduleAnimation();
        }
        }
    }
    }
@@ -4317,7 +4303,7 @@ class Task extends WindowContainer<WindowContainer> {
            // skip this for tasks created by the organizer because they can synchronously update
            // skip this for tasks created by the organizer because they can synchronously update
            // the leash before new children are added to the task.
            // the leash before new children are added to the task.
            if (!mCreatedByOrganizer && mTaskOrganizer != null && !prevHasBeenVisible) {
            if (!mCreatedByOrganizer && mTaskOrganizer != null && !prevHasBeenVisible) {
                getPendingTransaction().hide(getSurfaceControl());
                getSyncTransaction().hide(getSurfaceControl());
                commitPendingTransaction();
                commitPendingTransaction();
            }
            }


@@ -4500,7 +4486,7 @@ class Task extends WindowContainer<WindowContainer> {
     * @param hasFocus
     * @param hasFocus
     */
     */
    void onWindowFocusChanged(boolean hasFocus) {
    void onWindowFocusChanged(boolean hasFocus) {
        updateShadowsRadius(hasFocus, getPendingTransaction());
        updateShadowsRadius(hasFocus, getSyncTransaction());
    }
    }


    void onPictureInPictureParamsChanged() {
    void onPictureInPictureParamsChanged() {
Loading