When keyguard is being dismissed it still was overriding orientation for the display, which caused report of wrong configuration to activity that was becoming visible. Bug: 66979760 Bug: 36897968 Fixes: 68131425 Test: Launch Unity 4 based game, lock and unlock screen, check UI Test: com.android.server.wm.DisplayContentTests#testOrientationDefinedByKeyguard Change-Id: I0a180b8e941a85ba4174a40cdec2ff0b8f3e00eb