Skip to content
Snippets Groups Projects
Commit 7fe46bae authored by Santos Cordon's avatar Santos Cordon Committed by Android (Google) Code Review
Browse files

Merge "Send display-OFF event if that is initial state." into sc-dev

parents d00355cd a60654e0
No related branches found
No related tags found
No related merge requests found
......@@ -718,7 +718,12 @@ final class LocalDisplayAdapter extends DisplayAdapter {
setDisplayState(Display.STATE_ON);
currentState = Display.STATE_ON;
} else {
return; // old state and new state is off
if (oldState == Display.STATE_UNKNOWN) {
// There's no guarantee about what the initial state is
// at startup, so we have to set it if previous was UNKNOWN.
setDisplayState(state);
}
return;
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment