am 80bc0c48: am 73a6148e: am 82f0abc4: Merge "Workaround to prevent starting the same task from Recents twice. (Bug 17322903)" into lmp-dev

* commit '80bc0c48cdd472b8abd57b7cab143125b6d0f0a5':
  Workaround to prevent starting the same task from Recents twice. (Bug 17322903)
This commit is contained in:
Winson Chung
2014-09-02 07:09:51 +00:00
committed by Android Git Automerger

View File

@@ -67,6 +67,7 @@ public class RecentsView extends FrameLayout implements TaskStackView.TaskStackV
ArrayList<TaskStack> mStacks;
View mSearchBar;
RecentsViewCallbacks mCb;
boolean mAlreadyLaunchingTask;
public RecentsView(Context context) {
super(context);
@@ -120,6 +121,9 @@ public class RecentsView extends FrameLayout implements TaskStackView.TaskStackV
}
addView(stackView);
}
// Reset the launched state
mAlreadyLaunchingTask = false;
}
/** Removes all the task stack views from this recents view. */
@@ -381,6 +385,11 @@ public class RecentsView extends FrameLayout implements TaskStackView.TaskStackV
if (mCb != null) {
mCb.onTaskViewClicked();
}
// Skip if we are already launching tasks
if (mAlreadyLaunchingTask) {
return;
}
mAlreadyLaunchingTask = true;
// Upfront the processing of the thumbnail
TaskViewTransform transform = new TaskViewTransform();