Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 707c9334 authored by Ben Lin's avatar Ben Lin
Browse files

Prepare SysUI Builder before building it.

Some SysUI sub-classes run more preparation work, so run that before
actually building SysUI.

Bug: 171437275
Bug: 171436765
Bug: 171837859
Test: Boot OEM devices that require preparation, boots correctly
Change-Id: I7b83d83e38501ef531ef1b272738b21c6d2496a2
parent bae149c2
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -101,11 +101,13 @@ public class SystemUIFactory {
        if (initializeComponents) {
            // Only initialize when not starting from tests since this currently initializes some
            // components that shouldn't be run in the test environment
            builder = builder.setPip(mWMComponent.getPip())
            builder = prepareSysUIComponentBuilder(builder, mWMComponent)
                    .setPip(mWMComponent.getPip())
                    .setSplitScreen(mWMComponent.getSplitScreen())
                    .setOneHanded(mWMComponent.getOneHanded())
                    .setShellDump(mWMComponent.getShellDump());
        } else {
            // TODO: Call on prepareSysUIComponentBuilder but not with real components.
            builder = builder.setPip(Optional.ofNullable(null))
                    .setSplitScreen(Optional.ofNullable(null))
                    .setOneHanded(Optional.ofNullable(null))