title: Animating a view to be stacked on top of the view it is behind
body: <p>In my Android app, I have a view behind another view in a <code>FrameLayout</code>. I'd like to animate the hidden view at times so that it appears above the view that's shown. Here's my XML:</p>
  
  <pre><code>&lt;LinearLayout
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:layout_gravity="bottom"
      android:orientation="vertical"&gt;
  
      &lt;FrameLayout
          android:layout_width="match_parent"
          android:layout_height="wrap_content"&gt;
  
          &lt;LinearLayout
              android:id="@+id/options_container"
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
              android:orientation="horizontal"
              android:background="@color/light_gray"
              android:gravity="right"
              &gt;
  
              &lt;Button
                  android:id="@+id/option_button"
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:paddingEnd="8dp"
                  android:paddingRight="8dp"
                  android:background="@color/transparent"
                  android:text="@string/option_button"
                  android:textColor="@color/white"/&gt;
  
          &lt;/LinearLayout&gt;
  
          &lt;LinearLayout
              android:id="@+id/commentContainer"
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
              android:background="@color/white"
              android:elevation="5dp"
              android:paddingLeft="16dp"
              android:paddingStart="16dp"&gt;
  
              &lt;EditText
                  android:id="@+id/commentText"
                  android:layout_width="0dp"
                  android:layout_height="match_parent"
                  android:layout_weight="5"
                  android:maxLines="1"
                  android:inputType="textCapSentences"
                  /&gt;
  
              &lt;ImageButton
                  android:id="@+id/commentSubmit"
                  android:layout_width="0dp"
                  android:layout_height="match_parent"
                  android:layout_weight="1"
                  android:background="@color/light_gray"
                  android:textAllCaps="true"
                  android:text="@string/submit_comment"
                  android:src="@drawable/ic_send_white_24dp"
                  android:textColor="@color/white"/&gt;
          &lt;/LinearLayout&gt;
      &lt;/FrameLayout&gt;
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>Ideally, when I start typing in <code>commentText</code>, <code>options_container</code> would animate up above <code>commentContainer</code>. It seems like when I try to animate <code>options_container</code> though, nothing really happens. Just to check, I tried:</p>
  
  <pre><code>view.animate().y(200);
  </code></pre>
  
  <p>And I didn't see a change. Is this because what I'm trying to do is stack a view on top of another (by way of animation) inside of a <code>FrameLayout</code>?</p>