Do not enter resumeTopActivity recursively.

Changes for translucent activity were causing activities to be
launched twice due to a recursive call into resumeTopActivity.
Putting the translucent action onto a handler removes the recursivity
and fixes the multiple launch problem.

Fixes bug 10556969.

Change-Id: I2bb53cd555b0aaf093ab35db2859acb10b58211e
diff --git a/services/java/com/android/server/am/ActivityStack.java b/services/java/com/android/server/am/ActivityStack.java
index 8d27c5c..2b76e71 100644
--- a/services/java/com/android/server/am/ActivityStack.java
+++ b/services/java/com/android/server/am/ActivityStack.java
@@ -1110,8 +1110,10 @@
                                 case PAUSED:
                                     // This case created for transitioning activities from
                                     // translucent to opaque {@link Activity#convertToOpaque}.
-                                    mStackSupervisor.mStoppingActivities.remove(r);
-                                    stopActivityLocked(r);
+                                    if (!mStackSupervisor.mStoppingActivities.contains(r)) {
+                                        mStackSupervisor.mStoppingActivities.add(r);
+                                    }
+                                    mStackSupervisor.scheduleIdleLocked();
                                     break;
 
                                 default: