blob: ed88c6235d58fd1a4867d603c29b690312e163fe [file] [log] [blame]
Brad Stenning92e28352018-12-18 12:34:59 -08001<?xml version="1.0" encoding="utf-8"?>
2<!--
3 Copyright 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<!-- Car customizations
19 - Added title "Enter your PIN" under the entry field
20 - Put backspace and enter buttons in row 4
21 - PIN pad is on start side while entry field and title are on the end side
22 - Hid the emergency call at the bottom
23-->
24
25<com.android.keyguard.KeyguardPINView
26 xmlns:android="http://schemas.android.com/apk/res/android"
27 xmlns:app="http://schemas.android.com/apk/res-auto"
28 android:id="@+id/keyguard_pin_view"
29 android:layout_width="match_parent"
30 android:layout_height="match_parent"
31 android:orientation="horizontal"
32 android:paddingHorizontal="@dimen/car_margin">
33
34 <FrameLayout
35 android:layout_width="0dp"
36 android:layout_weight="1"
37 android:layout_height="match_parent">
38
39 <GridLayout
40 android:id="@+id/container"
41 android:layout_width="wrap_content"
42 android:layout_height="wrap_content"
43 android:layout_gravity="center"
44 android:gravity="center"
45 android:columnCount="3">
46
47 <include layout="@layout/num_pad_keys"/>
48 </GridLayout>
49 </FrameLayout>
50
51 <LinearLayout
52 android:layout_width="0dp"
53 android:layout_height="match_parent"
54 android:layout_weight="1"
55 android:gravity="center"
56 android:orientation="vertical">
57
58 <com.android.keyguard.PasswordTextView
59 android:id="@+id/pinEntry"
60 android:layout_width="@dimen/keyguard_security_width"
61 android:layout_height="@dimen/pin_entry_height"
62 android:gravity="center"
63 app:scaledTextSize="@integer/password_text_view_scale"
64 android:contentDescription="@string/keyguard_accessibility_pin_area" />
65
66 <View
67 android:id="@+id/divider"
68 android:layout_width="@dimen/keyguard_security_width"
69 android:layout_height="@dimen/divider_height"
70 android:background="@android:color/white" />
71
72 <TextView
73 android:layout_width="wrap_content"
74 android:layout_height="wrap_content"
75 android:layout_margin="@dimen/car_padding_2"
76 android:gravity="center"
77 android:textColor="@android:color/white"
78 android:textSize="@dimen/car_body1_size"
79 android:text="@string/keyguard_enter_your_pin" />
80
81 <include layout="@layout/keyguard_message_area" />
82
83 <Button
84 android:id="@+id/cancel_button"
85 android:layout_width="wrap_content"
86 android:layout_height="wrap_content"
87 android:layout_gravity="center"
88 style="@style/KeyguardButton"
89 android:text="@string/cancel"/>
90 </LinearLayout>
91
92 <!-- KeyguardPinView references these resources ids in code so removing them will cause the
93 keyguard to crash. Instead put them down here where they are out of the way and set their
94 visibility to gone. -->
95 <com.android.keyguard.AlphaOptimizedRelativeLayout
96 android:id="@+id/row0"
97 android:layout_width="0dp"
98 android:layout_height="0dp"
99 android:visibility="gone" />
100 <LinearLayout
101 android:id="@+id/row1"
102 android:layout_width="0dp"
103 android:layout_height="0dp"
104 android:visibility="gone" />
105 <LinearLayout
106 android:id="@+id/row2"
107 android:layout_width="0dp"
108 android:layout_height="0dp"
109 android:visibility="gone" />
110 <LinearLayout
111 android:id="@+id/row3"
112 android:layout_width="0dp"
113 android:layout_height="0dp"
114 android:visibility="gone" />
115 <LinearLayout
116 android:id="@+id/row4"
117 android:layout_width="0dp"
118 android:layout_height="0dp"
119 android:visibility="gone" />
120
121 <include layout="@layout/keyguard_eca"
122 android:id="@+id/keyguard_selector_fade_container"
123 android:layout_width="0dp"
124 android:layout_height="0dp"
125 android:visibility="gone" />
126</com.android.keyguard.KeyguardPINView>