]> Pileus Git - ~andy/freeotp/blob - res/layout/token.xml
Tablet UI rewrite
[~andy/freeotp] / res / layout / token.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <!--
3    - FreeOTP
4    -
5    - Authors: Nathaniel McCallum <npmccallum@redhat.com>
6    -
7    - Copyright (C) 2013  Nathaniel McCallum, Red Hat
8    -
9    - Licensed under the Apache License, Version 2.0 (the "License");
10    - you may not use this file except in compliance with the License.
11    - You may obtain a copy of the License at
12    -
13    -     http://www.apache.org/licenses/LICENSE-2.0
14    -
15    - Unless required by applicable law or agreed to in writing, software
16    - distributed under the License is distributed on an "AS IS" BASIS,
17    - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18    - See the License for the specific language governing permissions and
19    - limitations under the License.
20    -->
21
22 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
23     android:layout_width="match_parent"
24     android:layout_height="wrap_content"
25     android:layout_marginTop="4dp"
26     android:layout_marginBottom="4dp"
27     android:layout_marginLeft="8dp"
28     android:layout_marginRight="8dp"
29     android:background="@drawable/token"
30     android:orientation="vertical" >
31     <TextView
32         android:id="@+id/code"
33         android:layout_width="match_parent"
34         android:layout_height="60dp"
35         android:gravity="center"
36         android:paddingTop="4dp"
37         android:text="01234567"
38         android:textSize="48sp"
39         android:textStyle="bold"
40         android:typeface="monospace" />
41
42     <org.fedorahosted.freeotp.UrgencyProgressBar
43         android:id="@+id/progress"
44         style="?android:attr/progressBarStyleHorizontal"
45         android:layout_width="match_parent"
46         android:layout_height="wrap_content"
47         android:max="1000"
48         android:progress="500" />
49
50     <LinearLayout
51         android:layout_width="match_parent"
52         android:layout_height="wrap_content"
53         android:layout_margin="4dp"
54         android:orientation="horizontal" >
55
56         <LinearLayout
57             android:layout_width="0dp"
58             android:layout_height="wrap_content"
59             android:layout_weight="1"
60             android:orientation="vertical" >
61
62             <TextView
63                 android:id="@+id/issuer"
64                 android:layout_width="match_parent"
65                 android:layout_height="24dp"
66                 android:ellipsize="end"
67                 android:gravity="center_vertical"
68                 android:singleLine="true"
69                 android:text="example@example.com"
70                 android:textColor="@android:color/primary_text_light"
71                 android:textSize="16sp"
72                 android:textStyle="bold" />
73
74             <TextView
75                 android:id="@+id/label"
76                 android:layout_width="match_parent"
77                 android:layout_height="16dp"
78                 android:ellipsize="end"
79                 android:gravity="center_vertical"
80                 android:singleLine="true"
81                 android:text="1FMAS0M43MF98ASMDMF10MF0M"
82                 android:textColor="@android:color/secondary_text_light"
83                 android:textSize="12sp"
84                 android:textStyle="normal" />
85         </LinearLayout>
86
87         <CheckBox
88             android:id="@+id/checkBox"
89             android:layout_width="40dp"
90             android:layout_height="40dp"
91             android:background="?android:attr/selectableItemBackground" />
92     </LinearLayout>
93 </LinearLayout>