Hide hotseat when bubble bar is expanded.
Added logic to stash the hotseat when on launcher home screen.
Bug: 280494203
Test: Manual:
http://recall/-/gx8ASgewUeUS3QYohfrd1J/fjfjUw296LRXUm9uYqXU4K
all tests in com.android.launcher3.taskbar
Flag: com.android.wm.shell.enable_bubble_bar
Change-Id: I67b298831eaed9c549a2fae7dc5a0d9fae51f7c4
diff --git a/quickstep/src/com/android/launcher3/taskbar/LauncherTaskbarUIController.java b/quickstep/src/com/android/launcher3/taskbar/LauncherTaskbarUIController.java
index c29e60e..59bf8d5 100644
--- a/quickstep/src/com/android/launcher3/taskbar/LauncherTaskbarUIController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/LauncherTaskbarUIController.java
@@ -158,6 +158,11 @@
shouldDelayLauncherStateAnim);
}
+ @Override
+ public void stashHotseat(boolean stash) {
+ mTaskbarLauncherStateController.stashHotseat(stash);
+ }
+
/**
* Adds the Launcher resume animator to the given animator set.
*
diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarLauncherStateController.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarLauncherStateController.java
index ab3b44e..84c834b 100644
--- a/quickstep/src/com/android/launcher3/taskbar/TaskbarLauncherStateController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarLauncherStateController.java
@@ -17,9 +17,12 @@
import static com.android.app.animation.Interpolators.EMPHASIZED;
import static com.android.launcher3.LauncherState.HOTSEAT_ICONS;
+import static com.android.launcher3.Hotseat.ALPHA_CHANNEL_TASKBAR_ALIGNMENT;
+import static com.android.launcher3.Hotseat.ALPHA_CHANNEL_TASKBAR_STASH;
import static com.android.launcher3.taskbar.TaskbarStashController.FLAG_IN_APP;
import static com.android.launcher3.taskbar.TaskbarStashController.FLAG_IN_OVERVIEW;
import static com.android.launcher3.taskbar.TaskbarStashController.FLAG_IN_STASHED_LAUNCHER_STATE;
+import static com.android.launcher3.taskbar.TaskbarStashController.FLAG_STASHED_FOR_BUBBLES;
import static com.android.launcher3.taskbar.TaskbarViewController.ALPHA_INDEX_HOME;
import static com.android.launcher3.util.FlagDebugUtils.appendFlag;
import static com.android.launcher3.util.FlagDebugUtils.formatFlagChange;
@@ -41,6 +44,7 @@
import com.android.launcher3.AbstractFloatingView;
import com.android.launcher3.DeviceProfile;
+import com.android.launcher3.Hotseat.HotseatQsbAlphaId;
import com.android.launcher3.LauncherState;
import com.android.launcher3.QuickstepTransitionManager;
import com.android.launcher3.Utilities;
@@ -145,7 +149,7 @@
private AnimatedFloat mTaskbarBackgroundAlpha;
private AnimatedFloat mTaskbarAlpha;
private AnimatedFloat mTaskbarCornerRoundness;
- private MultiProperty mIconAlphaForHome;
+ private MultiProperty mTaskbarAlphaForHome;
private QuickstepLauncher mLauncher;
private boolean mIsDestroyed = false;
@@ -175,11 +179,11 @@
if (mIsQsbInline && !dp.isQsbInline) {
// We only modify QSB alpha if isQsbInline = true. If we switch to a DP
// where isQsbInline = false, then we need to reset the alpha.
- mLauncher.getHotseat().setQsbAlpha(1f);
+ mLauncher.getHotseat().setQsbAlpha(1f, ALPHA_CHANNEL_TASKBAR_ALIGNMENT);
}
mIsQsbInline = dp.isQsbInline;
TaskbarLauncherStateController.this.updateIconAlphaForHome(
- mIconAlphaForHome.getValue());
+ mTaskbarAlphaForHome.getValue(), ALPHA_CHANNEL_TASKBAR_ALIGNMENT);
}
};
@@ -242,7 +246,7 @@
.getTaskbarBackgroundAlpha();
mTaskbarAlpha = mControllers.taskbarDragLayerController.getTaskbarAlpha();
mTaskbarCornerRoundness = mControllers.getTaskbarCornerRoundness();
- mIconAlphaForHome = mControllers.taskbarViewController
+ mTaskbarAlphaForHome = mControllers.taskbarViewController
.getTaskbarIconAlpha().get(ALPHA_INDEX_HOME);
resetIconAlignment();
@@ -266,7 +270,7 @@
mIconAlignment.finishAnimation();
- mLauncher.getHotseat().setIconsAlpha(1f);
+ mLauncher.getHotseat().setIconsAlpha(1f, ALPHA_CHANNEL_TASKBAR_ALIGNMENT);
mLauncher.getStateManager().removeStateListener(mStateListener);
mCanSyncViews = !mControllers.taskbarActivityContext.isPhoneMode();
@@ -701,14 +705,17 @@
public void onAnimationEnd(Animator animation) {
if (isInStashedState && committed) {
// Reset hotseat alpha to default
- mLauncher.getHotseat().setIconsAlpha(1);
+ mLauncher.getHotseat().setIconsAlpha(1, ALPHA_CHANNEL_TASKBAR_ALIGNMENT);
}
}
@Override
public void onAnimationStart(Animator animation) {
- if (mLauncher.getHotseat().getIconsAlpha() > 0) {
- updateIconAlphaForHome(mLauncher.getHotseat().getIconsAlpha());
+ float hotseatIconsAlpha = mLauncher.getHotseat()
+ .getIconsAlpha(ALPHA_CHANNEL_TASKBAR_ALIGNMENT)
+ .getValue();
+ if (hotseatIconsAlpha > 0) {
+ updateIconAlphaForHome(hotseatIconsAlpha, ALPHA_CHANNEL_TASKBAR_ALIGNMENT);
}
}
});
@@ -737,6 +744,25 @@
}
}
+ protected void stashHotseat(boolean stash) {
+ TaskbarStashController stashController = mControllers.taskbarStashController;
+ stashController.updateStateForFlag(FLAG_STASHED_FOR_BUBBLES, stash);
+ Runnable swapHotseatWithTaskbar = new Runnable() {
+ @Override
+ public void run() {
+ updateIconAlphaForHome(stash ? 1 : 0, ALPHA_CHANNEL_TASKBAR_STASH);
+ }
+ };
+ if (stash) {
+ stashController.applyState();
+ // if we stashing the hotseat we need to immediately swap it with the animating taskbar
+ swapHotseatWithTaskbar.run();
+ } else {
+ // if we revert stashing make swap after taskbar animation is complete
+ stashController.applyState(/* postApplyAction = */ swapHotseatWithTaskbar);
+ }
+ }
+
/**
* Resets and updates the icon alignment.
*/
@@ -746,7 +772,7 @@
}
private void onIconAlignmentRatioChanged() {
- float currentValue = mIconAlphaForHome.getValue();
+ float currentValue = mTaskbarAlphaForHome.getValue();
boolean taskbarWillBeVisible = mIconAlignment.value < 1;
boolean firstFrameVisChanged = (taskbarWillBeVisible && Float.compare(currentValue, 1) != 0)
|| (!taskbarWillBeVisible && Float.compare(currentValue, 0) != 0);
@@ -754,8 +780,10 @@
mControllers.taskbarViewController.setLauncherIconAlignment(
mIconAlignment.value, mLauncher.getDeviceProfile());
mControllers.navbarButtonsViewController.updateTaskbarAlignment(mIconAlignment.value);
- // Switch taskbar and hotseat in last frame
- updateIconAlphaForHome(taskbarWillBeVisible ? 1 : 0);
+ // Switch taskbar and hotseat in last frame and if taskbar is not hidden for bubbles
+ boolean isHiddenForBubbles = mControllers.taskbarStashController.isHiddenForBubbles();
+ updateIconAlphaForHome(taskbarWillBeVisible ? 1 : 0, ALPHA_CHANNEL_TASKBAR_ALIGNMENT,
+ /* updateTaskbarAlpha = */ !isHiddenForBubbles);
// Sync the first frame where we swap taskbar and hotseat.
if (firstFrameVisChanged && mCanSyncViews && !Utilities.isRunningInTestHarness()) {
@@ -765,12 +793,20 @@
}
}
- private void updateIconAlphaForHome(float alpha) {
+ private void updateIconAlphaForHome(float taskbarAlpha, @HotseatQsbAlphaId int alphaChannel) {
+ updateIconAlphaForHome(taskbarAlpha, alphaChannel, /* updateTaskbarAlpha = */ true);
+ }
+
+ private void updateIconAlphaForHome(float taskbarAlpha,
+ @HotseatQsbAlphaId int alphaChannel,
+ boolean updateTaskbarAlpha) {
if (mIsDestroyed) {
return;
}
- mIconAlphaForHome.setValue(alpha);
- boolean hotseatVisible = alpha == 0
+ if (updateTaskbarAlpha) {
+ mTaskbarAlphaForHome.setValue(taskbarAlpha);
+ }
+ boolean hotseatVisible = taskbarAlpha == 0
|| mControllers.taskbarActivityContext.isPhoneMode()
|| (!mControllers.uiController.isHotseatIconOnTopWhenAligned()
&& mIconAlignment.value > 0);
@@ -778,9 +814,10 @@
* Hide Launcher Hotseat icons when Taskbar icons have opacity. Both icon sets
* should not be visible at the same time.
*/
- mLauncher.getHotseat().setIconsAlpha(hotseatVisible ? 1 : 0);
+ float targetAlpha = hotseatVisible ? 1 : 0;
+ mLauncher.getHotseat().setIconsAlpha(targetAlpha, alphaChannel);
if (mIsQsbInline) {
- mLauncher.getHotseat().setQsbAlpha(hotseatVisible ? 1 : 0);
+ mLauncher.getHotseat().setQsbAlpha(targetAlpha, alphaChannel);
}
}
@@ -868,7 +905,7 @@
pw.println(String.format(
"%s\tmTaskbarBackgroundAlpha=%.2f", prefix, mTaskbarBackgroundAlpha.value));
pw.println(String.format(
- "%s\tmIconAlphaForHome=%.2f", prefix, mIconAlphaForHome.getValue()));
+ "%s\tmTaskbarAlphaForHome=%.2f", prefix, mTaskbarAlphaForHome.getValue()));
pw.println(String.format("%s\tmPrevState=%s", prefix,
mPrevState == null ? null : getStateString(mPrevState)));
pw.println(String.format("%s\tmState=%s", prefix, getStateString(mState)));
diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarScrimViewController.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarScrimViewController.java
index 2370dfd..751a42a 100644
--- a/quickstep/src/com/android/launcher3/taskbar/TaskbarScrimViewController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarScrimViewController.java
@@ -115,7 +115,8 @@
return bubblesExpanded && !mControllers.navbarButtonsViewController.isImeVisible()
&& !isShadeVisible
&& !mControllers.taskbarStashController.isStashed()
- && (mTaskbarVisible || showScrimForBubbles);
+ && (mTaskbarVisible || showScrimForBubbles)
+ && !mControllers.taskbarStashController.isHiddenForBubbles();
}
private float getScrimAlpha() {
diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarStashController.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarStashController.java
index 2c2f65d..1f7b44f 100644
--- a/quickstep/src/com/android/launcher3/taskbar/TaskbarStashController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarStashController.java
@@ -101,6 +101,7 @@
public static final int FLAG_IN_OVERVIEW = 1 << 11; // launcher is in overview
// An internal no-op flag to determine whether we should delay the taskbar background animation
private static final int FLAG_DELAY_TASKBAR_BG_TAG = 1 << 12;
+ public static final int FLAG_STASHED_FOR_BUBBLES = 1 << 13; // show handle for stashed hotseat
// If any of these flags are enabled, isInApp should return true.
private static final int FLAGS_IN_APP = FLAG_IN_APP | FLAG_IN_SETUP;
@@ -122,7 +123,8 @@
// If any of these flags are enabled, the taskbar must be stashed.
private static final int FLAGS_FORCE_STASHED = FLAG_STASHED_SYSUI | FLAG_STASHED_DEVICE_LOCKED
- | FLAG_STASHED_IN_TASKBAR_ALL_APPS | FLAG_STASHED_SMALL_SCREEN;
+ | FLAG_STASHED_IN_TASKBAR_ALL_APPS | FLAG_STASHED_SMALL_SCREEN
+ | FLAG_STASHED_FOR_BUBBLES;
/**
* How long to stash/unstash when manually invoked via long press.
@@ -395,6 +397,11 @@
return mIsStashed;
}
+ /** Sets the hotseat stashed. */
+ public void stashHotseat(boolean stash) {
+ mControllers.uiController.stashHotseat(stash);
+ }
+
/**
* Returns whether the taskbar should be stashed in apps (e.g. user long pressed to stash).
*/
@@ -434,6 +441,11 @@
return hasAnyFlag(FLAG_IN_OVERVIEW);
}
+ /** Returns whether taskbar is hidden for bubbles. */
+ public boolean isHiddenForBubbles() {
+ return hasAnyFlag(FLAG_STASHED_FOR_BUBBLES);
+ }
+
/**
* Returns the height that taskbar will be touchable.
*/
@@ -995,13 +1007,29 @@
}
public void applyState() {
- applyState(hasAnyFlag(FLAG_IN_SETUP) ? 0 : TASKBAR_STASH_DURATION);
+ applyState(/* postApplyAction = */ null);
+ }
+
+ /** Applies state and performs action after state is applied. */
+ public void applyState(@Nullable Runnable postApplyAction) {
+ applyState(hasAnyFlag(FLAG_IN_SETUP) ? 0 : TASKBAR_STASH_DURATION, postApplyAction);
}
public void applyState(long duration) {
+ applyState(duration, /* postApplyAction = */ null);
+ }
+
+ private void applyState(long duration, @Nullable Runnable postApplyAction) {
Animator animator = createApplyStateAnimator(duration);
if (animator != null) {
+ if (postApplyAction != null) {
+ // performs action on animation end
+ animator.addListener(AnimatorListeners.forEndCallback(postApplyAction));
+ }
animator.start();
+ } else if (postApplyAction != null) {
+ // animator was not created, just execute the action
+ postApplyAction.run();
}
}
diff --git a/quickstep/src/com/android/launcher3/taskbar/TaskbarUIController.java b/quickstep/src/com/android/launcher3/taskbar/TaskbarUIController.java
index 6b1173a..c047216 100644
--- a/quickstep/src/com/android/launcher3/taskbar/TaskbarUIController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/TaskbarUIController.java
@@ -428,4 +428,8 @@
public void setSkipLauncherVisibilityChange(boolean skip) {
mSkipLauncherVisibilityChange = skip;
}
+
+ /** Sets whether the hotseat is stashed */
+ public void stashHotseat(boolean stash) {
+ }
}
diff --git a/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleBarViewController.java b/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleBarViewController.java
index ed08de5..4176292 100644
--- a/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleBarViewController.java
+++ b/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleBarViewController.java
@@ -440,7 +440,7 @@
if (hidden) {
mBarView.setAlpha(0);
mBarView.setExpanded(false);
- updatePersistentTaskbar(/* isBubbleBarExpanded = */ false);
+ adjustTaskbarAndHotseatToBubbleBarState(/* isBubbleBarExpanded = */ false);
}
mActivity.bubbleBarVisibilityChanged(!hidden);
}
@@ -735,7 +735,7 @@
public void setExpanded(boolean isExpanded) {
if (isExpanded != mBarView.isExpanded()) {
mBarView.setExpanded(isExpanded);
- updatePersistentTaskbar(isExpanded);
+ adjustTaskbarAndHotseatToBubbleBarState(isExpanded);
if (!isExpanded) {
mSystemUiProxy.collapseBubbles();
} else {
@@ -746,13 +746,20 @@
}
}
- private void updatePersistentTaskbar(boolean isBubbleBarExpanded) {
- if (mBubbleStashController.isTransientTaskBar()) return;
- boolean hideTaskbar = isBubbleBarExpanded && isIntersectingTaskbar();
- mTaskbarViewPropertiesProvider
- .getIconsAlpha()
- .animateToValue(hideTaskbar ? 0 : 1)
- .start();
+ /**
+ * Hides the persistent taskbar if it is going to intersect with the expanded bubble bar if in
+ * app or overview. Set the hotseat stashed state if on launcher home screen.
+ */
+ private void adjustTaskbarAndHotseatToBubbleBarState(boolean isBubbleBarExpanded) {
+ if (mBubbleStashController.isBubblesShowingOnHome()) {
+ mTaskbarStashController.stashHotseat(isBubbleBarExpanded);
+ } else if (!mBubbleStashController.isTransientTaskBar()) {
+ boolean hideTaskbar = isBubbleBarExpanded && isIntersectingTaskbar();
+ mTaskbarViewPropertiesProvider
+ .getIconsAlpha()
+ .animateToValue(hideTaskbar ? 0 : 1)
+ .start();
+ }
}
/** Return {@code true} if expanded bubble bar would intersect the taskbar. */
@@ -871,6 +878,11 @@
mBoundsChangeListener = listener;
}
+ /** Called when the controller is destroyed. */
+ public void onDestroy() {
+ adjustTaskbarAndHotseatToBubbleBarState(/*isBubbleBarExpanded = */false);
+ }
+
/**
* Create an animator for showing or hiding bubbles when stashed state changes
*
diff --git a/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleControllers.java b/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleControllers.java
index e00916a..293a3e4 100644
--- a/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleControllers.java
+++ b/quickstep/src/com/android/launcher3/taskbar/bubbles/BubbleControllers.java
@@ -124,6 +124,7 @@
public void onDestroy() {
bubbleStashedHandleViewController.ifPresent(BubbleStashedHandleViewController::onDestroy);
bubbleBarController.onDestroy();
+ bubbleBarViewController.onDestroy();
}
/** Dumps bubble controllers state. */
diff --git a/src/com/android/launcher3/Hotseat.java b/src/com/android/launcher3/Hotseat.java
index 0d4ebe0..024dde4 100644
--- a/src/com/android/launcher3/Hotseat.java
+++ b/src/com/android/launcher3/Hotseat.java
@@ -33,15 +33,34 @@
import android.view.ViewGroup;
import android.widget.FrameLayout;
+import androidx.annotation.IntDef;
+
import com.android.launcher3.util.HorizontalInsettableView;
+import com.android.launcher3.util.MultiPropertyFactory.MultiProperty;
import com.android.launcher3.util.MultiTranslateDelegate;
+import com.android.launcher3.util.MultiValueAlpha;
import com.android.launcher3.views.ActivityContext;
+import java.io.PrintWriter;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
/**
* View class that represents the bottom row of the home screen.
*/
public class Hotseat extends CellLayout implements Insettable {
+ public static final int ALPHA_CHANNEL_TASKBAR_ALIGNMENT = 0;
+ public static final int ALPHA_CHANNEL_PREVIEW_RENDERER = 1;
+ public static final int ALPHA_CHANNEL_TASKBAR_STASH = 2;
+ public static final int ALPHA_CHANNEL_CHANNELS_COUNT = 3;
+
+ @Retention(RetentionPolicy.RUNTIME)
+ @IntDef({ALPHA_CHANNEL_TASKBAR_ALIGNMENT, ALPHA_CHANNEL_PREVIEW_RENDERER,
+ ALPHA_CHANNEL_TASKBAR_STASH})
+ public @interface HotseatQsbAlphaId {
+ }
+
// Ratio of empty space, qsb should take up to appear visually centered.
public static final float QSB_CENTER_FACTOR = .325f;
private static final int BUBBLE_BAR_ADJUSTMENT_ANIMATION_DURATION_MS = 250;
@@ -50,6 +69,8 @@
private boolean mHasVerticalHotseat;
private Workspace<?> mWorkspace;
private boolean mSendTouchToWorkspace;
+ private final MultiValueAlpha mIconsAlphaChannels;
+ private final MultiValueAlpha mQsbAlphaChannels;
private final View mQsb;
@@ -63,9 +84,11 @@
public Hotseat(Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
-
mQsb = LayoutInflater.from(context).inflate(R.layout.search_container_hotseat, this, false);
addView(mQsb);
+ mIconsAlphaChannels = new MultiValueAlpha(getShortcutsAndWidgets(),
+ ALPHA_CHANNEL_CHANNELS_COUNT);
+ mQsbAlphaChannels = new MultiValueAlpha(mQsb, ALPHA_CHANNEL_CHANNELS_COUNT);
}
/**
@@ -270,21 +293,27 @@
}
/**
- * Sets the alpha value of just our ShortcutAndWidgetContainer.
+ * Sets the alpha value of the specified alpha channel of just our ShortcutAndWidgetContainer.
*/
- public void setIconsAlpha(float alpha) {
- getShortcutsAndWidgets().setAlpha(alpha);
+ public void setIconsAlpha(float alpha, @HotseatQsbAlphaId int channelId) {
+ getIconsAlpha(channelId).setValue(alpha);
}
/**
* Sets the alpha value of just our QSB.
*/
- public void setQsbAlpha(float alpha) {
- mQsb.setAlpha(alpha);
+ public void setQsbAlpha(float alpha, @HotseatQsbAlphaId int channelId) {
+ getQsbAlpha(channelId).setValue(alpha);
}
- public float getIconsAlpha() {
- return getShortcutsAndWidgets().getAlpha();
+ /** Returns the alpha channel for ShortcutAndWidgetContainer */
+ public MultiProperty getIconsAlpha(@HotseatQsbAlphaId int channelId) {
+ return mIconsAlphaChannels.get(channelId);
+ }
+
+ /** Returns the alpha channel for Qsb */
+ public MultiProperty getQsbAlpha(@HotseatQsbAlphaId int channelId) {
+ return mQsbAlphaChannels.get(channelId);
}
/**
@@ -294,4 +323,24 @@
return mQsb;
}
+ /** Dumps the Hotseat internal state */
+ public void dump(String prefix, PrintWriter writer) {
+ writer.println(prefix + "Hotseat:");
+ mIconsAlphaChannels.dump(
+ prefix + "\t",
+ writer,
+ "mIconsAlphaChannels",
+ "ALPHA_CHANNEL_TASKBAR_ALIGNMENT",
+ "ALPHA_CHANNEL_PREVIEW_RENDERER",
+ "ALPHA_CHANNEL_TASKBAR_STASH");
+ mQsbAlphaChannels.dump(
+ prefix + "\t",
+ writer,
+ "mQsbAlphaChannels",
+ "ALPHA_CHANNEL_TASKBAR_ALIGNMENT",
+ "ALPHA_CHANNEL_PREVIEW_RENDERER",
+ "ALPHA_CHANNEL_TASKBAR_STASH"
+ );
+ }
+
}
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index 365e3d4..fa7f564 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -2678,6 +2678,7 @@
}
writer.println(prefix + " Hotseat");
+ mHotseat.dump(prefix, writer);
ViewGroup layout = mHotseat.getShortcutsAndWidgets();
for (int j = 0; j < layout.getChildCount(); j++) {
Object tag = layout.getChildAt(j).getTag();
diff --git a/src/com/android/launcher3/graphics/LauncherPreviewRenderer.java b/src/com/android/launcher3/graphics/LauncherPreviewRenderer.java
index 2408955..4af9e2f 100644
--- a/src/com/android/launcher3/graphics/LauncherPreviewRenderer.java
+++ b/src/com/android/launcher3/graphics/LauncherPreviewRenderer.java
@@ -23,6 +23,7 @@
import static com.android.launcher3.BubbleTextView.DISPLAY_TASKBAR;
import static com.android.launcher3.BubbleTextView.DISPLAY_WORKSPACE;
import static com.android.launcher3.DeviceProfile.DEFAULT_SCALE;
+import static com.android.launcher3.Hotseat.ALPHA_CHANNEL_PREVIEW_RENDERER;
import static com.android.launcher3.LauncherSettings.Favorites.CONTAINER_HOTSEAT_PREDICTION;
import static com.android.launcher3.Utilities.SHOULD_SHOW_FIRST_PAGE_WIDGET;
import static com.android.launcher3.model.ModelUtils.filterCurrentWorkspaceItems;
@@ -320,12 +321,12 @@
mUiHandler.post(() -> {
if (mDp.isTaskbarPresent) {
// hotseat icons on bottom
- mHotseat.setIconsAlpha(hide ? 0 : 1);
+ mHotseat.setIconsAlpha(hide ? 0 : 1, ALPHA_CHANNEL_PREVIEW_RENDERER);
if (mDp.isQsbInline) {
- mHotseat.setQsbAlpha(hide ? 0 : 1);
+ mHotseat.setQsbAlpha(hide ? 0 : 1, ALPHA_CHANNEL_PREVIEW_RENDERER);
}
} else {
- mHotseat.setQsbAlpha(hide ? 0 : 1);
+ mHotseat.setQsbAlpha(hide ? 0 : 1, ALPHA_CHANNEL_PREVIEW_RENDERER);
}
});
}