activity_edit_account.xml

  1<?xml version="1.0" encoding="utf-8"?>
  2<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3    android:layout_width="match_parent"
  4    android:layout_height="match_parent"
  5    android:background="@color/primarybackground" >
  6
  7    <ScrollView
  8        android:layout_width="fill_parent"
  9        android:layout_height="wrap_content"
 10        android:layout_above="@+id/button_bar"
 11        android:layout_alignParentTop="true">
 12        <LinearLayout
 13            android:layout_width="match_parent"
 14            android:layout_height="wrap_content" 
 15            android:orientation="vertical">
 16
 17    <LinearLayout
 18        android:id="@+id/editor"
 19        android:layout_width="fill_parent"
 20        android:layout_height="wrap_content"
 21        android:orientation="vertical"
 22        android:padding="8dp" >
 23
 24        <TextView
 25            android:layout_width="wrap_content"
 26            android:layout_height="wrap_content"
 27            android:text="@string/account_settings_jabber_id"
 28            android:textColor="@color/primarytext"
 29            android:textSize="14sp" />
 30
 31        <AutoCompleteTextView
 32            android:id="@+id/account_jid"
 33            android:layout_width="match_parent"
 34            android:layout_height="wrap_content"
 35            android:hint="@string/account_settings_example_jabber_id"
 36            android:inputType="textEmailAddress" />
 37
 38        <TextView
 39            android:layout_width="wrap_content"
 40            android:layout_height="wrap_content"
 41            android:layout_marginTop="8dp"
 42            android:text="@string/account_settings_password"
 43            android:textColor="@color/primarytext"
 44            android:textSize="14sp" />
 45
 46        <EditText
 47            android:id="@+id/account_password"
 48            android:layout_width="match_parent"
 49            android:layout_height="wrap_content"
 50            android:hint="@string/password"
 51            android:inputType="textPassword" />
 52
 53        <CheckBox
 54            android:id="@+id/account_register_new"
 55            android:layout_width="wrap_content"
 56            android:layout_height="wrap_content"
 57            android:layout_marginTop="8dp"
 58            android:text="@string/register_account"
 59            android:textColor="@color/primarytext"
 60            android:textSize="14sp" />
 61
 62        <TextView
 63            android:id="@+id/account_confirm_password_desc"
 64            android:layout_width="wrap_content"
 65            android:layout_height="wrap_content"
 66            android:text="@string/account_settings_confirm_password"
 67            android:textColor="@color/primarytext"
 68            android:textSize="14sp"
 69            android:visibility="gone" />
 70
 71        <EditText
 72            android:id="@+id/account_password_confirm"
 73            android:layout_width="match_parent"
 74            android:layout_height="wrap_content"
 75            android:layout_marginTop="8dp"
 76            android:hint="@string/confirm_password"
 77            android:inputType="textPassword"
 78            android:visibility="gone" />
 79    </LinearLayout>
 80
 81    <LinearLayout
 82        android:id="@+id/stats"
 83        android:layout_width="fill_parent"
 84        android:layout_height="fill_parent"
 85        android:layout_marginTop="8dp"
 86        android:orientation="vertical"
 87        android:padding="16dp"
 88        android:visibility="gone" >
 89
 90        <TextView
 91            android:layout_width="fill_parent"
 92            android:layout_height="wrap_content"
 93            android:gravity="center_horizontal"
 94            android:text="@string/additional_information"
 95            android:textColor="@color/secondarytext"
 96            android:textSize="18sp"
 97            android:textStyle="bold" />
 98
 99        <TableLayout
100            android:layout_width="match_parent"
101            android:layout_height="wrap_content"
102            android:layout_marginTop="8dp"
103            android:stretchColumns="1" >
104
105            <TableRow
106                android:layout_width="fill_parent"
107                android:layout_height="wrap_content" >
108
109                <TextView
110                    android:layout_width="wrap_content"
111                    android:layout_height="wrap_content"
112                    android:text="@string/server_info_session_established" />
113
114                <TextView
115                    android:id="@+id/session_est"
116                    android:layout_width="wrap_content"
117                    android:layout_height="wrap_content"
118                    android:layout_gravity="right" />
119            </TableRow>
120
121            <TableRow
122                android:layout_width="fill_parent"
123                android:layout_height="wrap_content" >
124
125                <TextView
126                    android:layout_width="wrap_content"
127                    android:layout_height="wrap_content"
128                    android:text="@string/server_info_compatibilty" />
129
130                <TextView
131                    android:id="@+id/server_compat"
132                    android:layout_width="wrap_content"
133                    android:layout_height="wrap_content"
134                    android:layout_gravity="right" />
135            </TableRow>
136        </TableLayout>
137
138        <TextView
139            android:id="@+id/otr_fingerprint_headline"
140            android:layout_width="fill_parent"
141            android:layout_height="wrap_content"
142            android:layout_marginTop="16dp"
143            android:gravity="center_horizontal"
144            android:text="@string/otr_fingerprint"
145            android:textColor="@color/secondarytext"
146            android:textSize="18sp"
147            android:textStyle="bold" />
148
149        <TextView
150            android:id="@+id/otr_fingerprint"
151            android:layout_width="wrap_content"
152            android:layout_height="wrap_content"
153            android:layout_marginTop="8dp"
154            android:textSize="14sp"
155            android:typeface="monospace" />
156    </LinearLayout>
157    </LinearLayout>
158    </ScrollView>
159
160    <LinearLayout
161        android:id="@+id/button_bar"
162        android:layout_width="wrap_content"
163        android:layout_height="wrap_content"
164        android:layout_alignParentBottom="true"
165        android:layout_alignParentLeft="true"
166        android:layout_alignParentRight="true" >
167
168        <Button
169            android:id="@+id/cancel_button"
170            style="?android:attr/borderlessButtonStyle"
171            android:layout_width="0dp"
172            android:layout_height="wrap_content"
173            android:layout_weight="1"
174            android:text="@string/cancel"
175            android:textColor="@color/primarytext" />
176
177        <View
178            android:layout_width="1dp"
179            android:layout_height="fill_parent"
180            android:layout_marginBottom="7dp"
181            android:layout_marginTop="7dp"
182            android:background="@color/divider" />
183
184        <Button
185            android:id="@+id/save_button"
186            style="?android:attr/borderlessButtonStyle"
187            android:layout_width="0dp"
188            android:layout_height="wrap_content"
189            android:layout_weight="1"
190            android:enabled="false"
191            android:text="@string/save"
192            android:textColor="@color/secondarytext" />
193    </LinearLayout>
194
195</RelativeLayout>