title: Fragment shared element transition not working in nested views
body: <p>I have a strange problem (maybe it's a bug in transitions library) with shared element transition animations. Target <code>Android version</code> is <code>5.0</code>.</p>
  
  <p>Here is my layout:</p>
  
  <pre><code>&lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"                                     xmlns:tools="http://schemas.android.com/tools"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:id="@+id/root_layout"&gt;
  
          &lt;RelativeLayout
              android:id="@+id/content_frame"
              android:layout_width="match_parent"
              android:layout_height="match_parent"&gt;
  
              &lt;!-- The main content view --&gt;
              &lt;FrameLayout
                  android:id="@+id/content_main"
                  android:layout_width="match_parent"
                  android:layout_height="match_parent"
                  &gt;
              &lt;/FrameLayout&gt;
  
              &lt;!-- The second content view --&gt;
              &lt;FrameLayout
                  android:id="@+id/content_second"
                  android:layout_width="match_parent"
                  android:layout_height="match_parent"
                  &gt;
              &lt;/FrameLayout&gt;
  
          &lt;/RelativeLayout&gt;
  &lt;/RelativeLayout&gt;
  </code></pre>
  
  <p>I have 2 fragments (<code>FragmentA</code> and <code>FragmentB</code>). <code>FragmentA</code> has <code>imageViewA</code> and <code>FragmentB</code> has <code>imageViewA</code> with bigger size. Shared element transitions defined correctly and when <code>FragmentB</code> opens <code>imageViewA</code> animated correctly. </p>
  
  <p><strong>But</strong> it works just in case when <code>FragmentA</code> is added to <code>content_frame</code> container (root container). If I'm adding <code>FragmentA</code> to <code>content_main</code> container - animation not working at all. </p>
  
  <ul>
  <li>If I add to <code>content_second</code> container some view - animation is not working.</li>
  <li>If I keep <code>content_second</code> container empty - animation is not working.</li>
  <li>Even if I remove <code>content_second</code> container - animation is not working.</li>
  </ul>
  
  <p>Both fragments would be added to the same container (using <code>FragmentTransaction.replace</code>).</p>