Merge "Fixing sysui scrim not updating in landscape UI" into ub-launcher3-rvc-dev am: cf4e6cd055

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/11872996

Change-Id: I535bdfc4dfb5b6e57b611318c8ef9671fd656f0e
This commit is contained in:
TreeHugger Robot
2020-06-16 19:14:03 +00:00
committed by Automerger Merge Worker
@@ -244,13 +244,17 @@ public class ShelfScrimView extends ScrimView<BaseQuickstepLauncher>
@Override
protected void updateSysUiColors() {
// Use a light system UI (dark icons) if all apps is behind at least half of the
// status bar.
boolean forceChange = mShelfTop <= mLauncher.getDeviceProfile().getInsets().top / 2f;
if (forceChange) {
mLauncher.getSystemUiController().updateUiState(UI_STATE_SCRIM_VIEW, !mIsScrimDark);
if (mDrawingFlatColor) {
super.updateSysUiColors();
} else {
mLauncher.getSystemUiController().updateUiState(UI_STATE_SCRIM_VIEW, 0);
// Use a light system UI (dark icons) if all apps is behind at least half of the
// status bar.
boolean forceChange = mShelfTop <= mLauncher.getDeviceProfile().getInsets().top / 2f;
if (forceChange) {
mLauncher.getSystemUiController().updateUiState(UI_STATE_SCRIM_VIEW, !mIsScrimDark);
} else {
mLauncher.getSystemUiController().updateUiState(UI_STATE_SCRIM_VIEW, 0);
}
}
}