app/src/main/res/layout/activity_preset_store.xml
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
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:id="@+id/activity_preset"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="com.bedrock.padder.activity.PresetStoreActivity">
<View
android:id="@+id/status_bar"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_alignParentTop="true"
android:background="@color/dark_status_bar"/>
<RelativeLayout
android:id="@+id/layout_relative"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true">
<android.support.design.widget.CoordinatorLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<android.support.design.widget.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
android:visibility="visible">
<android.support.design.widget.CollapsingToolbarLayout
android:id="@+id/collapsing_toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:contentScrim="?attr/colorPrimary"
app:layout_scrollFlags="scroll|exitUntilCollapsed">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<ImageView
android:id="@+id/layout_image"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:adjustViewBounds="true"
android:scaleType="centerCrop"
android:src="@drawable/about_image_preset_store"
android:transitionName="transition"
app:layout_collapseMode="parallax"/>
<View
android:id="@+id/layout_text"
android:layout_width="0dp"
android:layout_height="0dp"
android:layout_alignParentBottom="true"
android:visibility="gone"
android:background="#28000000"/>
</RelativeLayout>
<android.support.v7.widget.Toolbar
android:id="@+id/actionbar_toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
app:layout_collapseMode="pin"/>
</android.support.design.widget.CollapsingToolbarLayout>
<android.support.design.widget.TabLayout
android:id="@+id/layout_tab_layout"
android:layout_width="match_parent"
android:layout_height="42dp"
android:background="@color/colorPresetStore"
app:tabBackground="?selectableItemBackgroundBorderless"
app:tabGravity="fill"
app:tabIndicatorColor="@color/colorAccent"
app:tabMode="fixed"
app:tabTextColor="@color/light_primary"/>
</android.support.design.widget.AppBarLayout>
<android.support.v4.view.ViewPager
android:id="@+id/layout_viewpager"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior"/>
<android.support.v4.widget.NestedScrollView
android:id="@+id/layout_nested_scrollview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone"
app:layout_behavior="@string/appbar_scrolling_view_behavior">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<RelativeLayout
android:id="@+id/layout_preset_store"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:focusableInTouchMode="true">
<!-- focusableInTouchMode for disable auto-scroll to recyclerView -->
<android.support.v7.widget.RecyclerView
android:id="@+id/layout_preset_store_recycler_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scrollbars="none"
android:visibility="gone"/>
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_marginTop="200dp">
<LinearLayout
android:id="@+id/layout_preset_store_recycler_view_loading"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_centerInParent="true"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="12dp"
android:text="@string/preset_store_loading_metadata"
android:textColor="@color/dark_secondary"
android:textSize="18sp"/>
<ProgressBar
style="?android:attr/progressBarStyleHorizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:indeterminate="true"
android:indeterminateTint="@color/amber"/>
</LinearLayout>
<LinearLayout
android:id="@+id/layout_preset_store_recycler_view_failed"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:gravity="center_horizontal"
android:orientation="vertical"
android:visibility="gone">
<ImageView
android:layout_width="64dp"
android:layout_height="64dp"
android:layout_marginBottom="8dp"
android:alpha="0.5"
app:srcCompat="@drawable/ic_disconnected_black"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/preset_store_loading_metadata_failure"
android:textColor="@color/dark_secondary"
android:textSize="18sp"/>
</LinearLayout>
</RelativeLayout>
</RelativeLayout>
<View
android:id="@+id/layout_margin"
android:layout_width="match_parent"
android:layout_height="0dp"
android:background="@color/transparent"/>
</LinearLayout>
</android.support.v4.widget.NestedScrollView>
</android.support.design.widget.CoordinatorLayout>
</RelativeLayout>
<include layout="@layout/fragment_fab"/>
<View
android:id="@+id/layout_placeholder"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/colorAccent"
android:visibility="gone"/>
</RelativeLayout>