Merge "Guard one more use of CentralSurfaces in NavBar" into tm-qpr-dev am: fee4f5374f am: 27fb261fd2

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20215963

Change-Id: I981eb5421aae1702af9649c1714f25c2bd6dcdc4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
TreeHugger Robot
2022-10-18 04:58:56 +00:00
committed by Automerger Merge Worker
2 changed files with 4 additions and 1 deletions

View File

@@ -679,7 +679,9 @@ public class NavigationBar extends ViewController<NavigationBarView> implements
public void onViewAttached() {
final Display display = mView.getDisplay();
mView.setComponents(mRecentsOptional);
mView.setComponents(mCentralSurfacesOptionalLazy.get().get().getPanelController());
if (mCentralSurfacesOptionalLazy.get().isPresent()) {
mView.setComponents(mCentralSurfacesOptionalLazy.get().get().getPanelController());
}
mView.setDisabledFlags(mDisabledFlags1, mSysUiFlagsContainer);
mView.setOnVerticalChangedListener(this::onVerticalChanged);
mView.setOnTouchListener(this::onNavigationTouch);

View File

@@ -148,6 +148,7 @@ public class NavigationBarView extends FrameLayout {
private NavigationBarInflaterView mNavigationInflaterView;
private Optional<Recents> mRecentsOptional = Optional.empty();
@Nullable
private NotificationPanelViewController mPanelView;
private RotationContextButton mRotationContextButton;
private FloatingRotationButton mFloatingRotationButton;