Fixed spacing on Intro & Edu screens

Test: It builds.
Fixes: 132370812
Change-Id: I7bfa8a7eae91ad9b0fc9b19c9a6bc019f884e729
This commit is contained in:
joshmccloskey
2019-05-09 16:01:13 -07:00
committed by Joshua Mccloskey
parent 43c09673ab
commit fe6784b57d
3 changed files with 17 additions and 19 deletions

View File

@@ -40,16 +40,14 @@
android:textAlignment="center"
android:text="@string/security_settings_face_enroll_education_message"/>
<com.google.android.setupdesign.view.RichTextView
android:id="@+id/error_text"
style="@style/SudDescription.Glif"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
<Space android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"/>
<FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginVertical="48dp">
android:layout_marginVertical="12dp">
<com.google.android.setupdesign.view.IllustrationVideoView
android:id="@+id/illustration_normal"
@@ -68,6 +66,10 @@
</FrameLayout>
<Space android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"/>
<!-- Contains the buttons and extra information text at the bottom -->
<LinearLayout
android:layout_width="match_parent"

View File

@@ -43,12 +43,13 @@
android:id="@+id/error_text"
style="@style/SudDescription.Glif"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
android:layout_height="wrap_content"
android:visibility="gone"/>
<FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginVertical="48dp">
android:layout_marginVertical="12dp">
<com.google.android.setupdesign.view.IllustrationVideoView
android:id="@+id/illustration_normal"
@@ -69,10 +70,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:paddingStart="16dp"
android:paddingEnd="16dp"
android:paddingTop="24dp">
android:orientation="horizontal">
<ImageView
android:layout_width="wrap_content"
@@ -80,7 +78,7 @@
android:background="@drawable/ic_face_enroll_introduction_shield">
</ImageView>
<Space
android:layout_width="8dp"
android:layout_width="24dp"
android:layout_height="wrap_content"/>
<TextView
android:layout_width="match_parent"
@@ -93,8 +91,6 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:paddingStart="16dp"
android:paddingEnd="16dp"
android:paddingTop="24dp">
<ImageView
@@ -103,7 +99,7 @@
android:background="@drawable/ic_face_enroll_introduction_visibility">
</ImageView>
<Space
android:layout_width="8dp"
android:layout_width="24dp"
android:layout_height="wrap_content"/>
<TextView
android:layout_width="match_parent"
@@ -116,8 +112,6 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:paddingStart="16dp"
android:paddingEnd="16dp"
android:paddingTop="24dp">
<ImageView
@@ -126,7 +120,7 @@
android:background="@drawable/ic_face_enroll_introduction_people">
</ImageView>
<Space
android:layout_width="8dp"
android:layout_width="24dp"
android:layout_height="wrap_content"/>
<TextView
android:layout_width="match_parent"

View File

@@ -164,9 +164,11 @@ public abstract class BiometricEnrollIntroduction extends BiometricEnrollBase
final int errorMsg = checkMaxEnrolled();
if (errorMsg == 0) {
mErrorText.setText(null);
mErrorText.setVisibility(View.GONE);
getNextButton().setVisibility(View.VISIBLE);
} else {
mErrorText.setText(errorMsg);
mErrorText.setVisibility(View.VISIBLE);
getNextButton().setText(getResources().getString(R.string.done));
getNextButton().setVisibility(View.VISIBLE);
}