Disable fetching of thumbnails when using snapshots.

- We don't keep the snapshots on the SysUI side so this is just a wasted
  call to load them (the rest of the metadata can still be prefetched
  though).

Test: Launch new tasks and ensure that we aren't fetching task snapshots
      without entering overview.

Change-Id: I1fe01a162f15e4f75b333e7e1bbe32d07e5d0b8d
This commit is contained in:
Winson Chung
2017-02-13 16:11:40 -08:00
parent 5b12734fb0
commit f88baf8b17

View File

@@ -130,6 +130,7 @@ public class RecentsImpl implements ActivityOptions.OnAnimationFinishedListener
launchOpts.numVisibleTaskThumbnails = 2;
launchOpts.onlyLoadForCache = true;
launchOpts.onlyLoadPausedActivities = true;
launchOpts.loadThumbnails = !ActivityManager.ENABLE_TASK_SNAPSHOTS;
loader.loadTasks(mContext, plan, launchOpts);
}
}