diff options
author | cyBerta <cyberta@riseup.net> | 2018-07-04 23:42:45 +0200 |
---|---|---|
committer | cyBerta <cyberta@riseup.net> | 2018-07-04 23:42:45 +0200 |
commit | ba94657badcc5a05214a057fa938124bdf1ad47a (patch) | |
tree | d2562627ba32973f0ffb5e29ff5578042c26acd0 /app/src/main/res/layout-xlarge | |
parent | d63dd4b36701f2f993e671f8cc3c5424b787e43a (diff) |
#8886 add layout for tablets and improve tablet and phone layouts in general by implementing dynamic layout changes when keyboard appears
Diffstat (limited to 'app/src/main/res/layout-xlarge')
5 files changed, 58 insertions, 144 deletions
diff --git a/app/src/main/res/layout-xlarge/a_add_provider.xml b/app/src/main/res/layout-xlarge/a_add_provider.xml new file mode 100644 index 00000000..1bca612e --- /dev/null +++ b/app/src/main/res/layout-xlarge/a_add_provider.xml @@ -0,0 +1,46 @@ +<?xml version="1.0" encoding="utf-8"?> +<android.support.constraint.ConstraintLayout 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" + style="@style/BitmaskActivity" + android:layout_width="match_parent" + android:layout_height="match_parent" + tools:context=".ProviderCredentialsBaseActivity"> + + <android.support.v7.widget.AppCompatImageView + android:layout_width="match_parent" + android:layout_height="match_parent" + app:srcCompat="@drawable/ic_colorsquare" + android:scaleType="centerCrop" + /> + + <android.support.constraint.Guideline + android:id="@+id/guideline_left" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:orientation="vertical" + app:layout_constraintGuide_percent="0.2" /> + + <android.support.constraint.Guideline + android:id="@+id/guideline_right" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:orientation="vertical" + app:layout_constraintGuide_percent="0.8" /> + + <android.support.constraint.Guideline + android:id="@+id/guideline_top" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:orientation="horizontal" + app:layout_constraintGuide_percent="0.15" /> + + <android.support.constraint.Guideline + android:id="@+id/guideline_bottom" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:orientation="horizontal" + app:layout_constraintGuide_percent="0.85" /> + + <include layout="@layout/a_add_provider_tablet_scrollview"/> +</android.support.constraint.ConstraintLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout-xlarge/a_provider_credentials.xml b/app/src/main/res/layout-xlarge/a_provider_credentials.xml index 79045082..f55f142c 100644 --- a/app/src/main/res/layout-xlarge/a_provider_credentials.xml +++ b/app/src/main/res/layout-xlarge/a_provider_credentials.xml @@ -42,59 +42,5 @@ android:orientation="horizontal" app:layout_constraintGuide_percent="0.85" /> - <LinearLayout - android:orientation="vertical" - style="@style/BitmaskActivity" - android:layout_width="0dp" - android:layout_height="0dp" - android:layout_margin="@dimen/stdpadding" - android:padding="@dimen/stdpadding" - android:background="@color/colorBackground" - app:layout_constraintBottom_toTopOf="@+id/guideline_bottom" - app:layout_constraintEnd_toStartOf="@+id/guideline_right" - app:layout_constraintHeight_min="411dp" - app:layout_constraintStart_toStartOf="@+id/guideline_left" - app:layout_constraintTop_toTopOf="@+id/guideline_top" - app:layout_constraintWidth_min="731dp"> - - <include layout="@layout/v_loading_screen" /> - - <LinearLayout - android:layout_width="match_parent" - android:layout_height="match_parent" - android:id="@+id/content" - android:orientation="vertical"> - - <include - layout="@layout/v_provider_header" - android:layout_width="match_parent" - android:layout_height="wrap_content" /> - - - <ScrollView - android:layout_height="match_parent" - android:layout_width="match_parent" - android:isScrollContainer="true" - > - - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="vertical"> - <include - layout="@layout/v_provider_credentials" - android:layout_width="match_parent" - android:layout_height="wrap_content" /> - - <android.support.v7.widget.AppCompatButton - android:id="@+id/button" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="end" - android:text="@string/login_button" /> - - </LinearLayout> - </ScrollView> - </LinearLayout> - </LinearLayout> + <include layout="@layout/a_provider_credentials_tablet_linear_layout"/> </android.support.constraint.ConstraintLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout-xlarge/a_provider_detail.xml b/app/src/main/res/layout-xlarge/a_provider_detail.xml index c1eeb0e0..ea677786 100644 --- a/app/src/main/res/layout-xlarge/a_provider_detail.xml +++ b/app/src/main/res/layout-xlarge/a_provider_detail.xml @@ -43,52 +43,5 @@ android:orientation="horizontal" app:layout_constraintGuide_percent="0.85" /> - <LinearLayout - android:orientation="vertical" - android:padding="@dimen/stdpadding" - style="@style/BitmaskActivity" - android:layout_width="0dp" - android:layout_height="0dp" - android:layout_margin="@dimen/stdpadding" - android:background="@color/colorBackground" - app:layout_constraintBottom_toTopOf="@+id/guideline_bottom" - app:layout_constraintEnd_toStartOf="@+id/guideline_right" - app:layout_constraintHeight_min="411dp" - app:layout_constraintStart_toStartOf="@+id/guideline_left" - app:layout_constraintTop_toTopOf="@+id/guideline_top" - app:layout_constraintWidth_min="731dp"> - - <include layout="@layout/v_loading_screen" /> - - <LinearLayout - android:id="@+id/content" - android:orientation="vertical" - android:layout_width="match_parent" - android:layout_height="wrap_content"> - - <include - layout="@layout/v_provider_header" - android:layout_width="match_parent" - android:layout_height="wrap_content" /> - - <android.support.v7.widget.AppCompatTextView - android:id="@+id/provider_detail_description" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:textStyle="normal" - android:textAppearance="?android:attr/textAppearanceMedium" - android:layout_marginTop="@dimen/standard_margin" - android:layout_marginBottom="@dimen/standard_margin" - /> - - <ListView - android:id="@+id/provider_detail_options" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_marginTop="@dimen/list_view_margin_top" - android:drawSelectorOnTop="false" - /> - - </LinearLayout> - </LinearLayout> + <include layout="@layout/a_provider_detail_tablet_linear_layout" /> </android.support.constraint.ConstraintLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout-xlarge/a_provider_list.xml b/app/src/main/res/layout-xlarge/a_provider_list.xml index 9150466a..4e666a90 100644 --- a/app/src/main/res/layout-xlarge/a_provider_list.xml +++ b/app/src/main/res/layout-xlarge/a_provider_list.xml @@ -43,41 +43,5 @@ android:orientation="horizontal" app:layout_constraintGuide_percent="0.85" /> - <LinearLayout - android:orientation="vertical" - android:padding="@dimen/stdpadding" - style="@style/BitmaskActivity" - android:layout_width="0dp" - android:layout_height="0dp" - android:layout_margin="@dimen/stdpadding" - android:background="@color/colorBackground" - app:layout_constraintBottom_toTopOf="@+id/guideline_bottom" - app:layout_constraintEnd_toStartOf="@+id/guideline_right" - app:layout_constraintHeight_min="411dp" - app:layout_constraintStart_toStartOf="@+id/guideline_left" - app:layout_constraintTop_toTopOf="@+id/guideline_top" - app:layout_constraintWidth_min="731dp"> - - <include layout="@layout/v_loading_screen" /> - - <LinearLayout - android:id="@+id/content" - android:orientation="vertical" - android:layout_width="match_parent" - android:layout_height="wrap_content"> - - <include layout="@layout/v_provider_header" - android:layout_width="match_parent" - android:layout_height="wrap_content" /> - - <ListView - android:id="@+id/provider_list" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:drawSelectorOnTop="false" - android:layout_marginTop="@dimen/list_view_margin_top" - /> - - </LinearLayout> - </LinearLayout> + <include layout="@layout/a_provider_list_tablet_linear_layout" /> </android.support.constraint.ConstraintLayout> diff --git a/app/src/main/res/layout-xlarge/v_provider_header.xml b/app/src/main/res/layout-xlarge/v_provider_header.xml index 45f8302b..6c06111a 100644 --- a/app/src/main/res/layout-xlarge/v_provider_header.xml +++ b/app/src/main/res/layout-xlarge/v_provider_header.xml @@ -1,11 +1,13 @@ <?xml version="1.0" encoding="utf-8"?> -<merge xmlns:android="http://schemas.android.com/apk/res/android" +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_height="wrap_content" + android:layout_width="match_parent" xmlns:app="http://schemas.android.com/apk/res-auto" > <android.support.v7.widget.AppCompatImageView android:id="@+id/provider_header_logo" - android:layout_width="@dimen/bitmask_logo_tablet" - android:layout_height="@dimen/bitmask_logo_tablet" + android:layout_width="@dimen/bitmask_logo" + android:layout_height="@dimen/bitmask_logo" android:adjustViewBounds="true" app:srcCompat="@drawable/mask" /> @@ -14,9 +16,12 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:text="" + android:ellipsize="end" + android:layout_below="@id/provider_header_logo" + android:gravity="center_vertical" android:textAppearance="@style/Base.TextAppearance.AppCompat.Headline" android:layout_marginTop="@dimen/standard_margin" android:layout_marginBottom="@dimen/standard_margin" /> -</merge>
\ No newline at end of file +</RelativeLayout>
\ No newline at end of file |