Skip to content
Snippets Groups Projects
Commit f3766f96 authored by Robert Beckett's avatar Robert Beckett Committed by Bernhard Rosenkränzer
Browse files

LogicalDisplayMappaer: allow external display to be default


deviceInfo already contains knowledge of whether the display should be
considered for the default display. LogicalDisplayMapper ignored this
information and stipulated that only internal displays can be default.

In the case of only external displays available, the first external
display should be considered the default to avoid boot failure as it
times out waiting for default display.

Use the deviceInfo provided flags to indicate default capability.

[bero@baylibre.com: Port to current AOSP]

Signed-off-by: default avatarRobert Beckett <bob.beckett@collabora.com>
Signed-off-by: default avatarBernhard Rosenkränzer <bero@baylibre.com>
Change-Id: I53947404fd491313b52f019806bac05499338e09
parent 2391f082
No related branches found
No related tags found
No related merge requests found
......@@ -572,7 +572,7 @@ class LogicalDisplayMapper implements DisplayDeviceRepository.Listener {
// Create a logical display for the new display device
LogicalDisplay display = createNewLogicalDisplayLocked(
device, Layout.assignDisplayIdLocked(false /*isDefault*/));
device, Layout.assignDisplayIdLocked((deviceInfo.flags & DisplayDeviceInfo.FLAG_ALLOWED_TO_BE_DEFAULT_DISPLAY) != 0));
applyLayoutLocked();
updateLogicalDisplaysLocked();
......
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