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

Commit 1de8afe2 authored by Riddle Hsu's avatar Riddle Hsu Committed by Android (Google) Code Review
Browse files

Merge "Reduce unnecessary redraw for non blast sync"

parents 214e635e a7d9247f
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -364,7 +364,7 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
    boolean mHidden = true;    // Used to determine if to show child windows.
    private boolean mDragResizing;
    private boolean mDragResizingChangeReported = true;
    private boolean mRedrawForSyncReported;
    private boolean mRedrawForSyncReported = true;

    /**
     * Used to assosciate a given set of state changes sent from MSG_RESIZED
@@ -5956,8 +5956,11 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
        mSyncSeqId++;
        if (getSyncMethod() == BLASTSyncEngine.METHOD_BLAST) {
            mPrepareSyncSeqId = mSyncSeqId;
        }
            requestRedrawForSync();
        } else if (mHasSurface && mWinAnimator.mDrawState != DRAW_PENDING) {
            // Only need to request redraw if the window has reported draw.
            requestRedrawForSync();
        }
        return true;
    }

+0 −4
Original line number Diff line number Diff line
@@ -428,10 +428,6 @@ class WindowStateAnimator {
        mShownAlpha = mAlpha;
    }

    private boolean isInBlastSync() {
        return mService.useBLASTSync() && mWin.useBLASTSync();
    }

    void prepareSurfaceLocked(SurfaceControl.Transaction t) {
        final WindowState w = mWin;
        if (!hasSurface()) {