edit_event_1.xml revision 5d89406c7ca7974b5fe61b21c82634f8726439ef
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2010 The Android Open Source Project
3
4     Licensed under the Apache License, Version 2.0 (the "License");
5     you may not use this file except in compliance with the License.
6     You may obtain a copy of the License at
7
8          http://www.apache.org/licenses/LICENSE-2.0
9
10     Unless required by applicable law or agreed to in writing, software
11     distributed under the License is distributed on an "AS IS" BASIS,
12     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13     See the License for the specific language governing permissions and
14     limitations under the License.
15-->
16<LinearLayout
17    xmlns:android="http://schemas.android.com/apk/res/android"
18    android:orientation="vertical"
19    android:layout_width="match_parent"
20    android:layout_height="wrap_content">
21
22    <!-- CALENDARS SELECTOR for new events -->
23    <LinearLayout
24        android:id="@+id/calendar_selector_group"
25        android:orientation="vertical"
26        android:layout_width="match_parent"
27        android:layout_height="wrap_content"
28        android:focusable="true" >
29        <Spinner
30            android:id="@+id/calendars_spinner"
31            android:prompt="@string/edit_event_calendar_label"
32            android:layout_height="wrap_content"
33            android:layout_width="match_parent"
34            android:layout_gravity="center_vertical"
35            android:paddingBottom="10dip"
36            android:paddingTop="10dip"
37            android:paddingLeft="8dip"
38            android:paddingRight="16dip"
39            android:layout_marginLeft="16dip"
40            android:layout_marginRight="16dip"
41            android:gravity="center_vertical" />
42    </LinearLayout>
43
44    <!-- CALENDAR DISPLAY for existing events -->
45    <LinearLayout
46        android:id="@+id/calendar_group"
47        android:orientation="vertical"
48        android:layout_width="match_parent"
49        android:layout_height="wrap_content"
50        android:paddingBottom="5dip"
51        android:paddingTop="5dip"
52        android:focusable="true">
53        <TextView
54            android:id="@+id/calendar_textview"
55            android:layout_height="wrap_content"
56            android:layout_width="match_parent"
57            android:textColor="#FFFFFFFF"
58            android:paddingLeft="8dip"
59            android:paddingRight="8dip"
60            android:layout_marginLeft="16dip"
61            android:layout_marginRight="16dip"
62            style="@style/TextAppearance.EditEvent_Value" />
63        <TextView
64            android:id="@+id/calendar_textview_secondary"
65            android:layout_height="wrap_content"
66            android:layout_width="match_parent"
67            android:textColor="#FFFFFFFF"
68            android:paddingLeft="8dip"
69            android:paddingRight="8dip"
70            android:layout_marginLeft="16dip"
71            android:layout_marginRight="16dip"
72            android:textSize="14sp"
73            style="@style/TextAppearance.EditEvent_Value" />
74    </LinearLayout>
75
76    <!-- WHAT -->
77    <EditText
78        android:id="@+id/title"
79        style="@style/TextAppearance.EditEvent_Value"
80        android:singleLine="true"
81        android:layout_width="match_parent"
82        android:layout_height="wrap_content"
83        android:hint="@string/hint_what"
84        android:capitalize="sentences"
85        android:focusable="true" />
86
87    <!-- WHERE -->
88    <LinearLayout android:id="@+id/where_row"
89        android:orientation="vertical"
90        android:layout_width="match_parent"
91        android:layout_height="wrap_content"
92        android:focusable="true">
93        <EditText
94            android:id="@+id/location"
95            android:singleLine="false"
96            android:layout_height="wrap_content"
97            android:layout_width="match_parent"
98            android:imeOptions="actionDone"
99            style="@style/TextAppearance.EditEvent_Value"
100            android:hint="@string/hint_where" />
101    <View
102        style="@style/EditEventSeparator"/>
103    </LinearLayout>
104
105    <!-- WHEN - Read-only textview version of FROM/TO (below) -->
106    <LinearLayout
107        android:id="@+id/when_row"
108        android:visibility="gone"
109        android:orientation="vertical"
110        android:layout_width="match_parent"
111        android:layout_height="wrap_content"
112        android:focusable="true">
113        <TextView
114            android:id="@+id/when_label"
115            android:text="@string/when_label"
116            android:layout_height="wrap_content"
117            android:layout_width="wrap_content"
118            android:layout_marginBottom="-8dip"
119            style="@style/TextAppearance.EditEvent_LabelSmall" />
120        <TextView
121            android:id="@+id/when"
122            android:layout_height="wrap_content"
123            android:layout_width="wrap_content"
124            style="@style/TextAppearance.EditEvent_Value" />
125    </LinearLayout>
126
127    <!-- FROM - Read/write version which launches the date/time pickers -->
128    <LinearLayout
129        android:id="@+id/from_row"
130        android:orientation="vertical"
131        android:layout_width="match_parent"
132        android:layout_height="wrap_content">
133        <TextView
134            android:id="@+id/from_label"
135            android:layout_height="wrap_content"
136            android:layout_width="match_parent"
137            android:text="@string/edit_event_from_label"
138            style="@style/TextAppearance.EditEvent_LabelSmall" />
139        <LinearLayout
140            android:layout_height="wrap_content"
141            android:layout_width="match_parent"
142            android:orientation="horizontal"
143            android:animateLayoutChanges="false">
144            <Button
145                android:id="@+id/start_date"
146                android:layout_width="0px"
147                android:layout_height="wrap_content"
148                android:layout_weight="7"
149                android:contentDescription="@string/accessibility_pick_start_date"
150                style="@style/TextAppearance.EditEvent_Spinner" />
151            <Button
152                android:id="@+id/start_time"
153                android:layout_width="0px"
154                android:layout_height="wrap_content"
155                android:layout_weight="4"
156                android:contentDescription="@string/accessibility_pick_start_time"
157                android:layout_marginLeft="-8dip"
158                style="@style/TextAppearance.EditEvent_Spinner" />
159        </LinearLayout>
160    </LinearLayout>
161    <LinearLayout android:id="@+id/from_row_home_tz"
162        android:visibility="gone"
163        android:orientation="horizontal"
164        android:layout_width="match_parent"
165        android:layout_height="wrap_content"
166        android:paddingBottom="8dip"
167        android:layout_marginLeft="24dip"
168        android:layout_marginRight="16dip"
169        android:focusable="true">
170        <TextView android:id="@+id/start_date_home_tz"
171            android:layout_width="wrap_content"
172            android:layout_height="wrap_content"
173            android:layout_weight="7"
174            android:gravity="left|center_vertical"
175            style="@style/TextAppearance.EditEvent_homeTime" />
176        <TextView android:id="@+id/start_time_home_tz"
177            android:layout_width="wrap_content"
178            android:layout_height="wrap_content"
179            android:layout_weight="4"
180            android:gravity="right|center_vertical"
181            style="@style/TextAppearance.EditEvent_homeTime" />
182    </LinearLayout>
183
184    <!-- TO - Read/write version which launches the date/time pickers -->
185    <LinearLayout
186        android:id="@+id/to_row"
187        android:orientation="vertical"
188        android:layout_width="match_parent"
189        android:layout_height="wrap_content">
190        <TextView
191            android:id="@+id/to_label"
192            android:text="@string/edit_event_to_label"
193            android:layout_height="wrap_content"
194            android:layout_width="match_parent"
195            style="@style/TextAppearance.EditEvent_LabelSmall" />
196        <LinearLayout
197            android:orientation="horizontal"
198            android:layout_height="wrap_content"
199            android:layout_width="match_parent"
200            android:animateLayoutChanges="false">
201            <Button
202                android:id="@+id/end_date"
203                android:layout_width="0px"
204                android:layout_height="wrap_content"
205                android:layout_weight="7"
206                android:contentDescription="@string/accessibility_pick_end_date"
207                style="@style/TextAppearance.EditEvent_Spinner" />
208            <Button
209                android:id="@+id/end_time"
210                android:layout_width="0px"
211                android:layout_height="wrap_content"
212                android:layout_weight="4"
213                android:contentDescription="@string/accessibility_pick_end_time"
214                android:layout_marginLeft="-8dip"
215                style="@style/TextAppearance.EditEvent_Spinner" />
216        </LinearLayout>
217    </LinearLayout>
218    <LinearLayout
219        android:id="@+id/to_row_home_tz"
220        android:visibility="gone"
221        android:focusable="true"
222        android:orientation="horizontal"
223        android:layout_width="match_parent"
224        android:layout_height="wrap_content"
225        android:paddingBottom="8dip"
226        android:layout_marginLeft="24dip"
227        android:layout_marginRight="16dip">
228        <TextView android:id="@+id/end_date_home_tz"
229            android:layout_width="wrap_content"
230            android:layout_height="wrap_content"
231            android:layout_weight="7"
232            android:gravity="left|center_vertical"
233            style="@style/TextAppearance.EditEvent_homeTime" />
234        <TextView android:id="@+id/end_time_home_tz"
235            android:layout_width="wrap_content"
236            android:layout_height="wrap_content"
237            android:layout_weight="4"
238            android:gravity="right|center_vertical"
239            style="@style/TextAppearance.EditEvent_homeTime" />
240    </LinearLayout>
241
242    <!-- ALL DAY -->
243    <LinearLayout
244        android:id="@+id/all_day_row"
245        android:orientation="horizontal"
246        android:gravity="center_vertical"
247        android:layout_width="match_parent"
248        android:layout_height="wrap_content">
249        <CheckBox
250            android:id="@+id/is_all_day"
251            android:layout_height="match_parent"
252            android:layout_width="wrap_content"
253            android:layout_gravity="center_vertical"
254            android:gravity="center_vertical"
255            android:layout_marginLeft="16dip"
256            android:layout_marginRight="0dip"
257            android:paddingLeft="0dip"
258            android:paddingRight="0dip"
259            android:contentDescription="@string/accessibility_all_day"/>
260        <TextView
261            android:id="@+id/is_all_day_label"
262            android:text="@string/edit_event_all_day_label"
263            android:layout_height="wrap_content"
264            android:layout_width="wrap_content"
265            android:paddingLeft="0dip"
266            android:layout_marginLeft="0dip"
267            android:layout_gravity="center_vertical"
268            style="@style/TextAppearance.EditEvent_Label" />
269    </LinearLayout>
270
271    <!-- TIME ZONE - Read-only textview version -->
272    <LinearLayout
273        android:id="@+id/timezone_textview_row"
274        android:visibility="gone"
275        android:orientation="vertical"
276        android:layout_width="match_parent"
277        android:layout_height="wrap_content"
278        android:focusable="true">
279        <TextView
280            android:id="@+id/timezone_textView"
281            android:layout_height="wrap_content"
282            android:layout_width="wrap_content"
283            style="@style/TextAppearance.EditEvent_Value" />
284    </LinearLayout>
285
286    <!-- TIME ZONE - Read/write version with button to launch picker -->
287    <LinearLayout
288        android:id="@+id/timezone_button_row"
289        android:orientation="vertical"
290        android:layout_width="match_parent"
291        android:layout_height="wrap_content">
292        <Button
293            android:id="@+id/timezone_button"
294            android:gravity="left|center_vertical"
295            android:layout_height="wrap_content"
296            android:layout_width="match_parent"
297            android:contentDescription="@string/accessibility_pick_time_zone"
298            style="@style/TextAppearance.EditEvent_Spinner" />
299    </LinearLayout>
300
301
302    <View
303        style="@style/EditEventSeparator"/>
304</LinearLayout>