wm: call displayReady for all built in displays when system is ready.
When system has more than one built in display, displayReady needs to be called for all built in displays when window manager is ready. Otherwise, some system services, such as presentation, mediarouter, etc, won't work on these displays. Bug: 24103683 Change-Id: Ibf08074eff555c14a318236bd06e7b4855503140
This commit is contained in:
committed by
Wale Ogunwale
parent
ac3b53a734
commit
6be61a98fc
@@ -642,6 +642,7 @@ public class WindowManagerService extends IWindowManager.Stub
|
||||
final InputManagerService mInputManager;
|
||||
final DisplayManagerInternal mDisplayManagerInternal;
|
||||
final DisplayManager mDisplayManager;
|
||||
final Display[] mDisplays;
|
||||
|
||||
// Who is holding the screen on.
|
||||
Session mHoldingScreenOn;
|
||||
@@ -915,8 +916,8 @@ public class WindowManagerService extends IWindowManager.Stub
|
||||
|
||||
mFxSession = new SurfaceSession();
|
||||
mDisplayManager = (DisplayManager)context.getSystemService(Context.DISPLAY_SERVICE);
|
||||
Display[] displays = mDisplayManager.getDisplays();
|
||||
for (Display display : displays) {
|
||||
mDisplays = mDisplayManager.getDisplays();
|
||||
for (Display display : mDisplays) {
|
||||
createDisplayContentLocked(display);
|
||||
}
|
||||
|
||||
@@ -7641,7 +7642,9 @@ public class WindowManagerService extends IWindowManager.Stub
|
||||
}
|
||||
|
||||
public void displayReady() {
|
||||
displayReady(Display.DEFAULT_DISPLAY);
|
||||
for (Display display : mDisplays) {
|
||||
displayReady(display.getDisplayId());
|
||||
}
|
||||
|
||||
synchronized(mWindowMap) {
|
||||
final DisplayContent displayContent = getDefaultDisplayContentLocked();
|
||||
|
||||
Reference in New Issue
Block a user