diff --git a/quickstep/src/com/android/launcher3/hybridhotseat/HotseatPredictionController.java b/quickstep/src/com/android/launcher3/hybridhotseat/HotseatPredictionController.java index 672bd1decf..6493234ea8 100644 --- a/quickstep/src/com/android/launcher3/hybridhotseat/HotseatPredictionController.java +++ b/quickstep/src/com/android/launcher3/hybridhotseat/HotseatPredictionController.java @@ -29,6 +29,7 @@ import android.animation.Animator; import android.animation.AnimatorSet; import android.animation.ObjectAnimator; import android.content.ComponentName; +import android.util.Log; import android.view.HapticFeedbackConstants; import android.view.View; import android.view.ViewGroup; @@ -80,6 +81,7 @@ public class HotseatPredictionController implements DragController.DragListener, SystemShortcut.Factory, DeviceProfile.OnDeviceProfileChangeListener, DragSource, ViewGroup.OnHierarchyChangeListener { + private static final String TAG = "HotseatPredictionController"; private static final int FLAG_UPDATE_PAUSED = 1 << 0; private static final int FLAG_DRAG_IN_PROGRESS = 1 << 1; private static final int FLAG_FILL_IN_PROGRESS = 1 << 2; @@ -291,6 +293,16 @@ public class HotseatPredictionController implements DragController.DragListener, } } + /** + * Ensures that if the flag FLAG_UPDATE_PAUSED is active we set it to false. + */ + public void verifyUIUpdateNotPaused() { + if ((mPauseFlags & FLAG_UPDATE_PAUSED) != 0) { + setPauseUIUpdate(false); + Log.e(TAG, "FLAG_UPDATE_PAUSED should not be set to true (see b/339700174)"); + } + } + /** * Sets or updates the predicted items */ diff --git a/quickstep/src/com/android/launcher3/uioverrides/QuickstepLauncher.java b/quickstep/src/com/android/launcher3/uioverrides/QuickstepLauncher.java index 1ea2cdc640..702997c442 100644 --- a/quickstep/src/com/android/launcher3/uioverrides/QuickstepLauncher.java +++ b/quickstep/src/com/android/launcher3/uioverrides/QuickstepLauncher.java @@ -389,6 +389,12 @@ public class QuickstepLauncher extends Launcher { return result; } + @Override + public void startBinding() { + super.startBinding(); + mHotseatPredictionController.verifyUIUpdateNotPaused(); + } + @Override protected void onActivityFlagsChanged(int changeBits) { if ((changeBits & ACTIVITY_STATE_STARTED) != 0) {