summaryrefslogtreecommitdiffstats
path: root/quickstep
diff options
context:
space:
mode:
authorTreeHugger Robot <treehugger-gerrit@google.com>2019-05-23 20:53:27 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2019-05-23 20:53:27 +0000
commit571e51161cb1e4ab7685aca5b370fba73c5727e6 (patch)
treec9fbb8572dd8f5aabdcf87e25989d03561c1e3ea /quickstep
parent1b9afd4f73830d0669ed5363f6b237096f2267ee (diff)
parent0c1ed7cb4cf6f5e46211731bb243bdb308c1eaac (diff)
downloadandroid_packages_apps_Trebuchet-571e51161cb1e4ab7685aca5b370fba73c5727e6.tar.gz
android_packages_apps_Trebuchet-571e51161cb1e4ab7685aca5b370fba73c5727e6.tar.bz2
android_packages_apps_Trebuchet-571e51161cb1e4ab7685aca5b370fba73c5727e6.zip
Merge "Quick patch for PredictionUiStateManager.applyState interrupting allapps" into ub-launcher3-qt-dev
Diffstat (limited to 'quickstep')
-rw-r--r--quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionUiStateManager.java3
-rw-r--r--quickstep/tests/src/com/android/quickstep/AppPredictionsUITests.java3
2 files changed, 6 insertions, 0 deletions
diff --git a/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionUiStateManager.java b/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionUiStateManager.java
index 6dad9afe5..28ecce07e 100644
--- a/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionUiStateManager.java
+++ b/quickstep/recents_ui_overrides/src/com/android/launcher3/appprediction/PredictionUiStateManager.java
@@ -197,7 +197,10 @@ public class PredictionUiStateManager implements OnGlobalLayoutListener, ItemInf
}
}
+ public boolean mDebugHadStateUpdate;
+
private void updatePredictionStateAfterCallback() {
+ mDebugHadStateUpdate = true;
boolean validResults = false;
for (List l : mPredictionServicePredictions) {
validResults |= l != null && !l.isEmpty();
diff --git a/quickstep/tests/src/com/android/quickstep/AppPredictionsUITests.java b/quickstep/tests/src/com/android/quickstep/AppPredictionsUITests.java
index 5e20e5643..c6f7544fe 100644
--- a/quickstep/tests/src/com/android/quickstep/AppPredictionsUITests.java
+++ b/quickstep/tests/src/com/android/quickstep/AppPredictionsUITests.java
@@ -70,6 +70,9 @@ public class AppPredictionsUITests extends AbstractQuickStepTest {
AppLaunchTracker.INSTANCE.initializeForTesting(new AppLaunchTracker());
PredictionUiStateManager.INSTANCE.initializeForTesting(null);
+ waitForLauncherCondition("Prediction never had state update",
+ launcher -> PredictionUiStateManager.INSTANCE.get(
+ mTargetContext).mDebugHadStateUpdate);
mCallback = PredictionUiStateManager.INSTANCE.get(mTargetContext).appPredictorCallback(
Client.HOME);