Fix split caused apps ANR
If mWindowDrawCountDown is set to non null when mReportNextDraw is false, it won't get cleared in performingDraw. If another draw occurs afterwards where mReportNextDraw is true, but requestDrawWindow doesn't get called, an ANR will occur. This is because performDraw will end up waiting forever since mWindowDrawCountDown was previously set to non null, but there will never be any calls reportDrawFinish to handle the countDown. We should only create latch and wait it when mReportNextDraw is true. Bug: 195262673 Test: Pass existing tests Test: Drag and drop split divider quickly Change-Id: I4ee81a41687c4f61a4828d4c61ba01abee795e89
Loading
Please register or sign in to comment