Files
app_Settings/res/layout/biometric_enroll_checkbox.xml
Kevin Chyn 87bb772e16 2/n: Add default implementation for multi-biometric enroll
1) Adds a layout for multi-biometric selection in BiometricEnrollActivity
2) Adds widgets for checkboxes
3) Shows ConfirmLock*/ChooseLock* for multi-biometric devices in
   BiometricEnrollActivity
4) finish()'s when loses foreground
5) Adds default string for ChooseLock* and multi-biometrics, e.g.
   "Set up Password + Biometrics", as well as associated plumbing
   to bring the user back to BiometricEnrollActivity once the
   credential is enrolled
6) When max templates enrolled, checkbox becomes disabled and
   description string is updated

Bug: 162341940
Bug: 152242790
Fixes: 161742393

No effect on existing devices with the following:
Test: adb shell am start -a android.settings.BIOMETRIC_ENROLL
Test: SUW
Test: make -j RunSettingsRoboTests

Exempt-From-Owner-Approval: Biometric-related change
to EncryptionInterstitial

Change-Id: I855460d50228ace24d4ec5fbe330f02ab406cc02
2020-09-16 23:30:11 -07:00

64 lines
2.2 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2018 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<!-- Icon -->
<ImageView
android:id="@+id/icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_alignParentStart="true" />
<!-- Title -->
<com.google.android.setupdesign.view.RichTextView
style="@style/SudDescription.Glif"
android:id="@+id/title"
android:paddingHorizontal="8dp"
android:paddingTop="16dp"
android:layout_marginBottom="4dp"
android:gravity="start"
android:layout_toEndOf="@+id/icon"
android:layout_toStartOf="@+id/checkbox"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<!-- Description -->
<TextView
android:id="@+id/description"
android:paddingHorizontal="8dp"
android:paddingBottom="16dp"
android:layout_toEndOf="@+id/icon"
android:layout_toStartOf="@+id/checkbox"
android:layout_below="@+id/title"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<!-- Check Box -->
<CheckBox
android:layout_alignParentEnd="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/checkbox"
android:layout_centerVertical="true"
android:checked="true"/>
</RelativeLayout>