Loading services/core/java/com/android/server/wm/DisplayContent.java +5 −0 Original line number Original line Diff line number Diff line Loading @@ -5264,6 +5264,11 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp return b; return b; } } // WARNING: it says `mSurfaceControl` below, but this CHANGES meaning after construction! // DisplayAreas are added in `configureSurface()` *before* `mSurfaceControl` gets replaced // with a wrapper or magnification surface so they end up in the right place; however, // anything added or reparented to "the display" *afterwards* needs to be reparented to // `getWindowinglayer()` (unless it's an overlay DisplayArea). return b.setName(child.getName()) return b.setName(child.getName()) .setParent(mSurfaceControl); .setParent(mSurfaceControl); } } Loading services/core/java/com/android/server/wm/Transition.java +6 −0 Original line number Original line Diff line number Diff line Loading @@ -1650,6 +1650,12 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener { // DisplayContent is the "root", so we reinterpret it's wc as the window layer // DisplayContent is the "root", so we reinterpret it's wc as the window layer // making the parent surface the displaycontent's surface. // making the parent surface the displaycontent's surface. return wc.getSurfaceControl(); return wc.getSurfaceControl(); } else if (wc.getParent().asDisplayContent() != null) { // DisplayContent is kinda split into 2 pieces, the "real root" and the // "windowing layer". So if the parent of the window is DC, then it really belongs on // the windowing layer (unless it's an overlay display area, but those can't be in // transitions anyways). return wc.getParent().asDisplayContent().getWindowingLayer(); } } return wc.getParent().getSurfaceControl(); return wc.getParent().getSurfaceControl(); } } Loading Loading
services/core/java/com/android/server/wm/DisplayContent.java +5 −0 Original line number Original line Diff line number Diff line Loading @@ -5264,6 +5264,11 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp return b; return b; } } // WARNING: it says `mSurfaceControl` below, but this CHANGES meaning after construction! // DisplayAreas are added in `configureSurface()` *before* `mSurfaceControl` gets replaced // with a wrapper or magnification surface so they end up in the right place; however, // anything added or reparented to "the display" *afterwards* needs to be reparented to // `getWindowinglayer()` (unless it's an overlay DisplayArea). return b.setName(child.getName()) return b.setName(child.getName()) .setParent(mSurfaceControl); .setParent(mSurfaceControl); } } Loading
services/core/java/com/android/server/wm/Transition.java +6 −0 Original line number Original line Diff line number Diff line Loading @@ -1650,6 +1650,12 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener { // DisplayContent is the "root", so we reinterpret it's wc as the window layer // DisplayContent is the "root", so we reinterpret it's wc as the window layer // making the parent surface the displaycontent's surface. // making the parent surface the displaycontent's surface. return wc.getSurfaceControl(); return wc.getSurfaceControl(); } else if (wc.getParent().asDisplayContent() != null) { // DisplayContent is kinda split into 2 pieces, the "real root" and the // "windowing layer". So if the parent of the window is DC, then it really belongs on // the windowing layer (unless it's an overlay display area, but those can't be in // transitions anyways). return wc.getParent().asDisplayContent().getWindowingLayer(); } } return wc.getParent().getSurfaceControl(); return wc.getParent().getSurfaceControl(); } } Loading