Merge "Revert "Temporarily enable screen wakelock logging in WM"" into oc-dev
am: 13059cc2ad
Change-Id: I079d34636465188b0d2bd231c798c44343bbc3b5
This commit is contained in:
@@ -858,20 +858,14 @@ class RootWindowContainer extends WindowContainer<DisplayContent> {
|
|||||||
final int privateflags = attrs.privateFlags;
|
final int privateflags = attrs.privateFlags;
|
||||||
boolean displayHasContent = false;
|
boolean displayHasContent = false;
|
||||||
|
|
||||||
if (DEBUG_KEEP_SCREEN_ON && (attrFlags & FLAG_KEEP_SCREEN_ON) != 0
|
|
||||||
&& w != mService.mLastWakeLockHoldingWindow) {
|
|
||||||
Slog.d(TAG_KEEP_SCREEN_ON, "handleNotObscuredLocked: " + w
|
|
||||||
+ " has FLAG_KEEP_SCREEN_ON set, hasSurface=" + w.mHasSurface
|
|
||||||
+ ", canBeSeen=" + canBeSeen);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (w.mHasSurface && canBeSeen) {
|
if (w.mHasSurface && canBeSeen) {
|
||||||
if ((attrFlags & FLAG_KEEP_SCREEN_ON) != 0) {
|
if ((attrFlags & FLAG_KEEP_SCREEN_ON) != 0) {
|
||||||
mHoldScreen = w.mSession;
|
mHoldScreen = w.mSession;
|
||||||
mHoldScreenWindow = w;
|
mHoldScreenWindow = w;
|
||||||
} else if (DEBUG_KEEP_SCREEN_ON && w == mService.mLastWakeLockHoldingWindow) {
|
} else if (DEBUG_KEEP_SCREEN_ON && w == mService.mLastWakeLockHoldingWindow) {
|
||||||
Slog.d(TAG_KEEP_SCREEN_ON, "handleNotObscuredLocked: " + w + " was holding "
|
Slog.d(TAG_KEEP_SCREEN_ON, "handleNotObscuredLocked: " + w + " was holding "
|
||||||
+ "screen wakelock but no longer has FLAG_KEEP_SCREEN_ON!!!");
|
+ "screen wakelock but no longer has FLAG_KEEP_SCREEN_ON!!! called by"
|
||||||
|
+ Debug.getCallers(10));
|
||||||
}
|
}
|
||||||
if (!syswin && w.mAttrs.screenBrightness >= 0 && mScreenBrightness < 0) {
|
if (!syswin && w.mAttrs.screenBrightness >= 0 && mScreenBrightness < 0) {
|
||||||
mScreenBrightness = w.mAttrs.screenBrightness;
|
mScreenBrightness = w.mAttrs.screenBrightness;
|
||||||
|
|||||||
@@ -77,5 +77,5 @@ public class WindowManagerDebugConfig {
|
|||||||
static final boolean DEBUG_UNKNOWN_APP_VISIBILITY = false;
|
static final boolean DEBUG_UNKNOWN_APP_VISIBILITY = false;
|
||||||
|
|
||||||
static final String TAG_KEEP_SCREEN_ON = "DebugKeepScreenOn";
|
static final String TAG_KEEP_SCREEN_ON = "DebugKeepScreenOn";
|
||||||
static final boolean DEBUG_KEEP_SCREEN_ON = true;
|
static final boolean DEBUG_KEEP_SCREEN_ON = false;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user