Don't make home stack visible if starting activity isn't translucent

We allow the home stack to be visible right behind the fullscreen
stack if all the activities fullscreen stack are translucent and
visible. However, if we are starting an acitvity it isn't visible
yet so our check for translucent activities in the fullscreen
stack will return true since there is nothing visible. This will
cause the home stack to the visible and the visiblilty of its app
token set to true in window manager and it been factored into the
transition animation.

In addition to checking if the activity is visible, we now also
check if it is the starting activity when trying to determine if
the stack is translucent.

Bug: 27448511
Change-Id: Icbbd57c0632cc5389c7ac894800a41f75d4bc450
diff --git a/services/core/java/com/android/server/am/ActivityMetricsLogger.java b/services/core/java/com/android/server/am/ActivityMetricsLogger.java
index 0e6dd28..43e1bdf 100644
--- a/services/core/java/com/android/server/am/ActivityMetricsLogger.java
+++ b/services/core/java/com/android/server/am/ActivityMetricsLogger.java
@@ -61,7 +61,7 @@
         mLastLogTimeSecs = now;
 
         ActivityStack stack = mSupervisor.getStack(DOCKED_STACK_ID);
-        if (stack != null && stack.getStackVisibilityLocked() != STACK_INVISIBLE) {
+        if (stack != null && stack.getStackVisibilityLocked(null) != STACK_INVISIBLE) {
             mWindowState = WINDOW_STATE_SIDE_BY_SIDE;
             return;
         }