diff options
author | Jeff Brown <jeffbrown@google.com> | 2012-10-16 16:19:23 -0700 |
---|---|---|
committer | Jeff Brown <jeffbrown@google.com> | 2012-10-16 16:19:23 -0700 |
commit | 8ec0943a7963178da838e4b6b842ec1109707b35 (patch) | |
tree | b0df09e42fcd740003e3e3cfa29e71f8444be665 /services/java/com/android/server/display/DisplayManagerService.java | |
parent | 016ff14f12900a12499a434b297b2192b62ff2da (diff) |
Blank all displays including Wifi Display when screen is off.
Calling blank() on Surface Flinger to turn the screen off is not
enough to ensure that the content is blanked to all virtual displays.
What's more, the black surface left in place by the ElectronBeam may
not completely hide the content (particularly if the display orientation
changes). To fix this for real, we'll want to move the display power
management code from the power manager into the display manager
but we don't have time for that.
As a work around, force all displays to show an empty layer stack
with no surfaces on it while blanked.
Bug: 7311959
Change-Id: I870c985f9e76f3f2322e5d83cdbbed9ed15b9f10
Diffstat (limited to 'services/java/com/android/server/display/DisplayManagerService.java')
-rw-r--r-- | services/java/com/android/server/display/DisplayManagerService.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/services/java/com/android/server/display/DisplayManagerService.java b/services/java/com/android/server/display/DisplayManagerService.java index 0a4252813188..93896af4b58b 100644 --- a/services/java/com/android/server/display/DisplayManagerService.java +++ b/services/java/com/android/server/display/DisplayManagerService.java @@ -305,6 +305,8 @@ public final class DisplayManagerService extends IDisplayManager.Stub { DisplayDevice device = mDisplayDevices.get(i); device.blankLocked(); } + + scheduleTraversalLocked(false); } } } @@ -322,6 +324,8 @@ public final class DisplayManagerService extends IDisplayManager.Stub { DisplayDevice device = mDisplayDevices.get(i); device.unblankLocked(); } + + scheduleTraversalLocked(false); } } } @@ -755,7 +759,9 @@ public final class DisplayManagerService extends IDisplayManager.Stub { + device.getDisplayDeviceInfoLocked()); return; } else { - display.configureDisplayInTransactionLocked(device); + boolean isBlanked = (mAllDisplayBlankStateFromPowerManager + == DISPLAY_BLANK_STATE_BLANKED); + display.configureDisplayInTransactionLocked(device, isBlanked); } // Update the viewports if needed. |