1<?xml version="1.0" encoding="utf-8"?>
2<!--
3  ~ Copyright (C) 2018 The Android Open Source Project
4  ~
5  ~ Licensed under the Apache License, Version 2.0 (the "License");
6  ~ you may not use this file except in compliance with the License.
7  ~ You may obtain a copy of the License at
8  ~
9  ~      http://www.apache.org/licenses/LICENSE-2.0
10  ~
11  ~ Unless required by applicable law or agreed to in writing, software
12  ~ distributed under the License is distributed on an "AS IS" BASIS,
13  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  ~ See the License for the specific language governing permissions and
15  ~ limitations under the License
16  -->
17
18<com.google.android.setupdesign.GlifLayout
19    xmlns:android="http://schemas.android.com/apk/res/android"
20    xmlns:app="http://schemas.android.com/apk/res-auto"
21    style="?attr/face_layout_theme"
22    android:id="@+id/setup_wizard_layout"
23    android:layout_width="match_parent"
24    android:layout_height="match_parent"
25    app:sucHeaderText="@string/security_settings_face_enroll_education_title">
26
27    <LinearLayout
28        style="@style/SudContentFrame"
29        android:layout_width="match_parent"
30        android:layout_height="match_parent"
31        android:clipChildren="false"
32        android:clipToPadding="false"
33        android:orientation="vertical">
34
35        <Space android:layout_width="match_parent"
36               android:layout_height="0dp"
37               android:layout_weight="1"/>
38
39        <FrameLayout
40            android:layout_width="match_parent"
41            android:layout_height="wrap_content"
42            android:layout_marginTop="@dimen/face_enroll_education_lottie_frame_margin_top">
43
44            <com.google.android.setupdesign.view.IllustrationVideoView
45                android:id="@+id/illustration_default"
46                style="@style/SudContentIllustration"
47                android:layout_width="wrap_content"
48                android:layout_height="wrap_content"
49                app:sudVideo="@raw/face_education"/>
50
51            <!-- Animation res MUST be set in code, gated by config_face_education_use_lottie. -->
52            <com.airbnb.lottie.LottieAnimationView
53                android:id="@+id/illustration_lottie"
54                android:layout_width="match_parent"
55                android:layout_height="@dimen/illustration_lottie_height"
56                android:layout_marginTop="@dimen/lottie_animation_view_margin_top"
57                android:scaleType="centerInside"
58                android:visibility="gone"
59                app:lottie_autoPlay="true"
60                app:lottie_loop="true"
61                app:lottie_speed="1.5" />
62
63            <ImageView
64                android:id="@+id/illustration_accessibility"
65                android:layout_width="wrap_content"
66                android:layout_height="wrap_content"
67                android:layout_gravity="center"
68                android:visibility="invisible"
69                android:layout_marginTop="@dimen/illustration_accessibility_margin_top"
70                android:src="@drawable/face_enroll_icon_large"/>
71
72        </FrameLayout>
73
74        <Space android:layout_width="match_parent"
75               android:layout_height="0dp"
76               android:layout_weight="1"/>
77
78        <!-- Contains the buttons and extra information text at the bottom -->
79        <LinearLayout
80            android:layout_width="match_parent"
81            android:layout_height="wrap_content"
82            android:orientation="vertical"
83            android:layout_gravity="center_horizontal|bottom">
84
85            <FrameLayout
86                android:layout_width="match_parent"
87                android:layout_height="wrap_content">
88
89                <Button
90                    android:id="@+id/accessibility_button"
91                    style="@style/SudGlifButton.Secondary"
92                    android:layout_gravity="center"
93                    android:layout_width="wrap_content"
94                    android:layout_height="wrap_content"
95                    android:layout_marginTop="@dimen/limited_vision_button_margin_top"
96                    android:layout_marginBottom="@dimen/limited_vision_button_margin_bottom"
97                    android:text="@string/security_settings_face_enroll_introduction_accessibility"/>
98
99                <com.android.settings.biometrics.face.FaceEnrollAccessibilityToggle
100                    android:id="@+id/toggle_diversity"
101                    android:layout_width="match_parent"
102                    android:layout_height="wrap_content"
103                    android:layout_marginTop="@dimen/limited_vision_button_toggle_margin_top"
104                    android:visibility="gone"
105                    app:messageText="@string/security_settings_face_enroll_introduction_accessibility"/>
106
107            </FrameLayout>
108
109        </LinearLayout>
110
111    </LinearLayout>
112
113</com.google.android.setupdesign.GlifLayout>
114