[CD Taskbar] Null Protect Taskbar against onLauncherVisibilityChange crash

Null Protect Taskbar against onLauncherVisibilityChange crash.

Flag: EXEMPT not adding new behavior
Bug: 403294086
Bug: 404928723
Test: m
Change-Id: I84e899d26f93d484031073d1b63c6757daa8b141
This commit is contained in:
Sukesh Ram
2025-03-20 05:10:42 -07:00
parent 59a89b2655
commit cb38ecbc8c
2 changed files with 13 additions and 7 deletions
@@ -495,7 +495,8 @@ public class TaskbarViewController implements TaskbarControllers.LoggableTaskbar
View[] iconViews = mTaskbarView.getIconViews();
float finalScale;
if (mControllers.getSharedState().startTaskbarVariantIsTransient) {
TaskbarSharedState sharedState = mControllers.getSharedState();
if (sharedState != null || mControllers.getSharedState().startTaskbarVariantIsTransient) {
finalScale = mapRange(scale, 1f, ((float) mPersistentIconSize / mTransientIconSize));
} else {
finalScale = mapRange(scale, ((float) mTransientIconSize / mPersistentIconSize), 1f);