Skip to content

Commit

Permalink
Improved -land/scrollable layouts
Browse files Browse the repository at this point in the history
  • Loading branch information
heinrichreimer committed Apr 2, 2016
1 parent f4c3019 commit 9cd78fc
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 58 deletions.
34 changes: 11 additions & 23 deletions library/src/main/res/layout-land/fragment_simple_slide.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,29 +6,21 @@
android:baselineAligned="false"
android:clipToPadding="false"
android:fitsSystemWindows="false"
android:padding="@dimen/mi_baseline">
android:paddingLeft="@dimen/mi_baseline"
android:paddingRight="@dimen/mi_baseline"
android:paddingTop="@dimen/mi_baseline"
android:paddingBottom="@dimen/mi_pager_margin_bottom">

<LinearLayout
<ImageView
android:id="@id/mi_image"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:layout_margin="@dimen/mi_baseline"
android:layout_gravity="center"
android:gravity="center"
android:orientation="vertical">

<ImageView
android:id="@id/mi_image"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="@dimen/mi_baseline"
android:gravity="center"
tools:ignore="ContentDescription"
tools:src="@android:drawable/sym_action_call"/>

<android.support.v4.widget.Space
android:layout_width="match_parent"
android:layout_height="@dimen/mi_pager_margin_bottom"/>

</LinearLayout>
tools:ignore="ContentDescription"
tools:src="@android:drawable/sym_action_call"/>

<LinearLayout
android:layout_width="0dp"
Expand Down Expand Up @@ -65,10 +57,6 @@
android:gravity="center"
android:text="@plurals/mi_label_grant_permission"/>

<android.support.v4.widget.Space
android:layout_width="match_parent"
android:layout_height="@dimen/mi_pager_margin_bottom"/>

</LinearLayout>

</LinearLayout>
Original file line number Diff line number Diff line change
Expand Up @@ -3,39 +3,31 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false"
android:fitsSystemWindows="false">

<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:baselineAligned="false"
android:padding="@dimen/mi_baseline">
android:paddingLeft="@dimen/mi_baseline"
android:paddingRight="@dimen/mi_baseline"
android:paddingTop="@dimen/mi_baseline"
android:paddingBottom="@dimen/mi_pager_margin_bottom">

<LinearLayout
<ImageView
android:id="@id/mi_image"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center_horizontal"
android:orientation="vertical">

<ImageView
android:id="@id/mi_image"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="@dimen/mi_baseline"
android:gravity="center"
tools:ignore="ContentDescription"
tools:src="@android:drawable/sym_action_call"/>

<android.support.v4.widget.Space
android:layout_width="match_parent"
android:layout_height="@dimen/mi_pager_margin_bottom"/>

</LinearLayout>
android:layout_height="wrap_content"
android:layout_margin="@dimen/mi_baseline"
android:gravity="center"
tools:ignore="ContentDescription"
tools:src="@android:drawable/sym_action_call"/>

<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center_horizontal"
android:orientation="vertical">
Expand Down Expand Up @@ -68,10 +60,6 @@
android:gravity="center"
android:text="@plurals/mi_label_grant_permission"/>

<android.support.v4.widget.Space
android:layout_width="match_parent"
android:layout_height="@dimen/mi_pager_margin_bottom"/>

</LinearLayout>

</LinearLayout>
Expand Down
9 changes: 4 additions & 5 deletions library/src/main/res/layout/fragment_simple_slide.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@
android:fitsSystemWindows="false"
android:gravity="center"
android:orientation="vertical"
android:padding="@dimen/mi_baseline">
android:paddingLeft="@dimen/mi_baseline"
android:paddingRight="@dimen/mi_baseline"
android:paddingTop="@dimen/mi_baseline"
android:paddingBottom="@dimen/mi_pager_margin_bottom">

<TextView
android:id="@id/mi_title"
Expand Down Expand Up @@ -46,8 +49,4 @@
android:gravity="center"
android:text="@plurals/mi_label_grant_permission"/>

<android.support.v4.widget.Space
android:layout_width="match_parent"
android:layout_height="@dimen/mi_pager_margin_bottom" />

</LinearLayout>
11 changes: 6 additions & 5 deletions library/src/main/res/layout/fragment_simple_slide_scrollable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,19 @@
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_height="match_parent"
android:clipToPadding="false"
android:fitsSystemWindows="false"
android:paddingBottom="@dimen/mi_pager_margin_bottom">
android:fitsSystemWindows="false">

<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="vertical"
android:padding="@dimen/mi_baseline">
android:paddingLeft="@dimen/mi_baseline"
android:paddingRight="@dimen/mi_baseline"
android:paddingTop="@dimen/mi_baseline"
android:paddingBottom="@dimen/mi_pager_margin_bottom">

<TextView
android:id="@id/mi_title"
Expand Down

0 comments on commit 9cd78fc

Please sign in to comment.