Set non-starting visible resumed activity as resumed activity for the stack

When ensuring visible activities for a stack we check to see if there is
already a resumed activity on the stack, so if we need to start an
activity that needs to be visible, we start it in the paused state
if there is already a resumed activity in the stack. This was't
taking into account a non-starting, visible, and resumed activity.

One case this can happen is if the currently resumed activity in
the stack becomes translucent and the activity behind it needs to
be started because it was previously destroyed due to low memory.

Bug: 19636839
Change-Id: I31670fd64d3bcbbf41823f51518ca603c7412e92
diff --git a/services/core/java/com/android/server/wm/WindowState.java b/services/core/java/com/android/server/wm/WindowState.java
index ec70879..c50974c 100644
--- a/services/core/java/com/android/server/wm/WindowState.java
+++ b/services/core/java/com/android/server/wm/WindowState.java
@@ -1709,7 +1709,7 @@
                     pw.println(mWallpaperDisplayOffsetY);
         }
         if (mDrawLock != null) {
-            pw.println("mDrawLock=" + mDrawLock);
+            pw.print(prefix); pw.println("mDrawLock=" + mDrawLock);
         }
     }