Merge "Workaround for assist crash with multiwindow" into nyc-dev

am: 9fb0e97ecb

* commit '9fb0e97ecb732585d3c8855b459fd1f8e52f7d2b':
  Workaround for assist crash with multiwindow

Change-Id: Ia026329d903ed525990614f9b046bbed3579a96b
This commit is contained in:
Amith Yamasani
2016-05-09 21:11:33 +00:00
committed by android-build-merger

View File

@@ -251,7 +251,8 @@ final class VoiceInteractionSessionConnection implements ServiceConnection {
&& structureEnabled) {
mAssistData.clear();
final int count = activityToken != null ? 1 : topActivities.size();
for (int i = 0; i < count; i++) {
// Temp workaround for bug: 28348867 Revert after DP3
for (int i = 0; i < count && i < 1; i++) {
IBinder topActivity = count == 1 ? activityToken : topActivities.get(i);
try {
MetricsLogger.count(mContext, "assist_with_context", 1);