Only update handle alpha on system UI flag update.
Added logic to check if handle view alpha should be updated during SysUi flag updates. Fixes: 417125892 Test: Manual. Create a new bubble on the home screen, observe the stash handle is not visible. Have stashed bubble bar and multiple system languages. Go to settings (or ane other apps that has input fields). Click on search to trigger keyboard pop up. Observe that stash handle is hidden. Collapse the keyboard and observe that stash handle is shown again. Flag: EXEMPT bug-fix Change-Id: I0976f37ca24ba816ee5eed6d4f1b4e6999b54c29
This commit is contained in:
@@ -33,12 +33,14 @@ import android.os.Bundle;
|
||||
import android.os.SystemProperties;
|
||||
import android.util.ArrayMap;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
import com.android.launcher3.taskbar.TaskbarSharedState;
|
||||
import com.android.launcher3.taskbar.bubbles.stashing.BubbleStashController;
|
||||
import com.android.launcher3.util.Executors.SimpleThreadFactory;
|
||||
import com.android.launcher3.util.MultiPropertyFactory;
|
||||
import com.android.quickstep.SystemUiProxy;
|
||||
import com.android.systemui.shared.system.QuickStepContract.SystemUiStateFlags;
|
||||
import com.android.wm.shell.Flags;
|
||||
@@ -237,8 +239,19 @@ public class BubbleBarController extends IBubblesListener.Stub {
|
||||
mBubbleBarViewController.setHiddenForSysui(hideBubbleBar);
|
||||
|
||||
boolean hideHandleView = (flags & MASK_HIDE_HANDLE_VIEW) != 0;
|
||||
mBubbleStashedHandleViewController.ifPresent(
|
||||
controller -> controller.setHiddenForSysui(hideHandleView));
|
||||
mBubbleStashedHandleViewController.ifPresent(controller -> {
|
||||
controller.setHiddenForSysui(hideHandleView);
|
||||
MultiPropertyFactory<View>.MultiProperty handleViewAlpha =
|
||||
mBubbleStashController.getHandleViewAlpha();
|
||||
boolean shouldShowHandleView = handleViewAlpha != null
|
||||
&& !hideHandleView
|
||||
&& mBubbleStashController.isStashed()
|
||||
&& mBubbleBarViewController.hasBubbles();
|
||||
if (shouldShowHandleView) {
|
||||
// TODO: (b/273592694) animate it?
|
||||
handleViewAlpha.setValue(1f);
|
||||
}
|
||||
});
|
||||
|
||||
boolean sysuiLocked = (flags & MASK_SYSUI_LOCKED) != 0;
|
||||
mBubbleStashController.setSysuiLocked(sysuiLocked);
|
||||
|
||||
-1
@@ -226,7 +226,6 @@ public class BubbleStashedHandleViewController {
|
||||
private void updateVisibilityForStateChange() {
|
||||
if (!mHiddenForSysui && !mHiddenForHomeButtonDisabled && !mHiddenForNoBubbles) {
|
||||
mStashedHandleView.setVisibility(VISIBLE);
|
||||
mStashedHandleView.setAlpha(1);
|
||||
} else {
|
||||
mStashedHandleView.setVisibility(INVISIBLE);
|
||||
mStashedHandleView.setAlpha(0);
|
||||
|
||||
Reference in New Issue
Block a user