title: build CollapsingToolbar with an ImageView along with a custom layout at the bottom
body: <p>This is what I want to achieve, there will be a custom layout below the image in a CollapsingToolbar, the layout will contain a couple of view items. <a href="https://ibin.co/4mY6hCv1DYAj.jpg" rel="nofollow noreferrer">1</a></p>
  
  <p>The required behaviour is, upon scrolling, the bottom layout will gradually fade and disappear and the image on top will shrink in size and gets pinned up as a toolbar.</p>
  
  <p>I have already built a CollapsingToolbar using just an image and it's working fine. Though I'm stuck at adding a custom layout at the bottom as said.</p>
  
  <p>Do I need to skip CollapsingToolbar and use something else such as MotionLayout ??</p>
  
  <pre><code>&lt;android.support.design.widget.CoordinatorLayout
  xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:app="http://schemas.android.com/apk/res-auto"
  xmlns:tools="http://schemas.android.com/tools"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  xmlns:fresco="http://schemas.android.com/apk/res-auto"
  tools:ignore="RtlHardcoded"&gt;
  
  
  &lt;android.support.design.widget.AppBarLayout
      android:id="@+id/main.appbar"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"&gt;
  
      &lt;android.support.design.widget.CollapsingToolbarLayout
          android:id="@+id/main.collapsing"
          android:layout_width="match_parent"
          android:layout_height="wrap_content"
          app:layout_scrollFlags="scroll|exitUntilCollapsed|snap"&gt;
  
          &lt;com.facebook.drawee.view.SimpleDraweeView
              android:id="@+id/sdv_add_iamge_header"
              android:layout_width="match_parent"
              android:layout_height="160dp"
              app:overlayImage="@color/trans_black"
              android:tint="#11000000"
              app:layout_collapseMode="parallax"
              app:layout_collapseParallaxMultiplier="0.5"
              app:actualImageScaleType="centerCrop"/&gt;
  
  
          &lt;FrameLayout
              android:id="@+id/main.framelayout.title"
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
              android:orientation="vertical"
              android:layout_marginTop="230dp"
              app:layout_collapseMode="parallax"
              app:layout_collapseParallaxMultiplier="0.2"
              app:layout_scrollFlags="scroll"&gt;
  
              &lt;RelativeLayout
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
              android:orientation="horizontal"&gt;
  
              &lt;/RelativeLayout&gt;
          &lt;/FrameLayout&gt;
  
  
          &lt;android.support.v7.widget.Toolbar
              android:id="@+id/main.toolbar"
              android:layout_width="match_parent"
              android:layout_height="?attr/actionBarSize"
              app:layout_collapseMode="pin"&gt;
                  &lt;ImageView
                      android:id="@+id/btn_back"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:src="@drawable/back"
                      style="@style/Widget.AppCompat.ActionButton"
                      android:layout_centerVertical="true"
                      android:layout_alignParentLeft="true" /&gt;
  
          &lt;/android.support.v7.widget.Toolbar&gt;
  
      &lt;/android.support.design.widget.CollapsingToolbarLayout&gt;
  &lt;/android.support.design.widget.AppBarLayout&gt;
  
  
          &lt;com.jude.easyrecyclerview.EasyRecyclerView
              android:id="@+id/list"
              android:name="com.socialinfotech.feeedj.TimeLineActivities.ViewCompanyDetailsActivity"
              android:layout_width="match_parent"
              android:layout_height="match_parent"
              app:layoutManager="LinearLayoutManager"
              android:scrollbars="none"
              app:behavior_overlapTop="30dp"
              app:layout_progress="@layout/view_progrss"
              app:layout_behavior="@string/appbar_scrolling_view_behavior"
              tools:context="com.socialinfotech.feeedj.TimeLineActivities.ViewCompanyDetailsActivity"
              tools:listitem="@layout/fragment_item" /&gt;
  </code></pre>
  
  <p></p>