Loading services/core/java/com/android/server/wm/WindowState.java +2 −1 Original line number Diff line number Diff line Loading @@ -5700,7 +5700,8 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP // window becomes visible while the sync group is still active. return true; } if (mSyncState == SYNC_STATE_WAITING_FOR_DRAW && mLastConfigReportedToClient && isDrawn()) { if (mSyncState == SYNC_STATE_WAITING_FOR_DRAW && mLastConfigReportedToClient && isDrawn() && mPrepareSyncSeqId <= 0) { // Complete the sync state immediately for a drawn window that doesn't need to redraw. onSyncFinishedDrawing(); } Loading services/tests/wmtests/src/com/android/server/wm/WindowOrganizerTests.java +2 −1 Original line number Diff line number Diff line Loading @@ -1376,8 +1376,9 @@ public class WindowOrganizerTests extends WindowTestsBase { assertTrue(w1.syncNextBuffer()); assertTrue(w2.syncNextBuffer()); // A drawn window can complete the sync state automatically. // A drawn window in non-explicit sync can complete the sync state automatically. w1.mWinAnimator.mDrawState = WindowStateAnimator.HAS_DRAWN; w1.mPrepareSyncSeqId = 0; makeLastConfigReportedToClient(w1, true /* visible */); mWm.mSyncEngine.onSurfacePlacement(); verify(mockCallback).onTransactionReady(anyInt(), any()); Loading Loading
services/core/java/com/android/server/wm/WindowState.java +2 −1 Original line number Diff line number Diff line Loading @@ -5700,7 +5700,8 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP // window becomes visible while the sync group is still active. return true; } if (mSyncState == SYNC_STATE_WAITING_FOR_DRAW && mLastConfigReportedToClient && isDrawn()) { if (mSyncState == SYNC_STATE_WAITING_FOR_DRAW && mLastConfigReportedToClient && isDrawn() && mPrepareSyncSeqId <= 0) { // Complete the sync state immediately for a drawn window that doesn't need to redraw. onSyncFinishedDrawing(); } Loading
services/tests/wmtests/src/com/android/server/wm/WindowOrganizerTests.java +2 −1 Original line number Diff line number Diff line Loading @@ -1376,8 +1376,9 @@ public class WindowOrganizerTests extends WindowTestsBase { assertTrue(w1.syncNextBuffer()); assertTrue(w2.syncNextBuffer()); // A drawn window can complete the sync state automatically. // A drawn window in non-explicit sync can complete the sync state automatically. w1.mWinAnimator.mDrawState = WindowStateAnimator.HAS_DRAWN; w1.mPrepareSyncSeqId = 0; makeLastConfigReportedToClient(w1, true /* visible */); mWm.mSyncEngine.onSurfacePlacement(); verify(mockCallback).onTransactionReady(anyInt(), any()); Loading