summaryrefslogtreecommitdiffstats
path: root/Android/05-UserInterface/UILab/res/layout
diff options
context:
space:
mode:
Diffstat (limited to 'Android/05-UserInterface/UILab/res/layout')
-rw-r--r--Android/05-UserInterface/UILab/res/layout/add_todo.xml181
-rw-r--r--Android/05-UserInterface/UILab/res/layout/footer_view.xml10
-rw-r--r--Android/05-UserInterface/UILab/res/layout/todo_item.xml73
3 files changed, 264 insertions, 0 deletions
diff --git a/Android/05-UserInterface/UILab/res/layout/add_todo.xml b/Android/05-UserInterface/UILab/res/layout/add_todo.xml
new file mode 100644
index 0000000..095ecf2
--- /dev/null
+++ b/Android/05-UserInterface/UILab/res/layout/add_todo.xml
@@ -0,0 +1,181 @@
+<?xml version="1.0" encoding="utf-8"?>
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent"
+ android:orientation="vertical" >
+
+ <!-- Title -->
+
+ <TextView
+ android:id="@+id/TitleLabel"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="@string/title_string"
+ android:textAppearance="?android:attr/textAppearanceLarge" >
+ </TextView>
+
+ <EditText
+ android:id="@+id/title"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@+id/TitleLabel"
+ android:layout_marginTop="14dp"
+ android:ems="10"
+ android:hint="@string/enter_title_string"
+ android:inputType="textShortMessage">
+
+ <requestFocus />
+ </EditText>
+
+ <!-- Status -->
+
+ <TextView
+ android:id="@+id/status"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@+id/title"
+ android:layout_marginTop="25dp"
+ android:text="@string/status_string"
+ android:textAppearance="?android:attr/textAppearanceLarge" />
+
+ <RadioGroup
+ android:id="@+id/statusGroup"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@id/status"
+ android:orientation="horizontal"
+ android:layout_marginTop="12dp" >
+
+ <RadioButton
+ android:id="@+id/statusDone"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="@string/done_string" />
+
+ <RadioButton
+ android:id="@+id/statusNotDone"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:checked="true"
+ android:text="@string/not_done_string" />
+ </RadioGroup>
+
+ <!-- Priority -->
+
+ <TextView
+ android:id="@+id/priority"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@id/statusGroup"
+ android:layout_marginTop="25dp"
+ android:text="@string/priority_string"
+ android:textAppearance="?android:attr/textAppearanceLarge" />
+
+ <RadioGroup
+ android:id="@+id/priorityGroup"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@id/priority"
+ android:orientation="horizontal"
+ android:layout_marginTop="12dp"
+ android:text="@string/priority_string" >
+
+ <RadioButton
+ android:id="@+id/lowPriority"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="@string/priority_low_string" />
+
+ <RadioButton
+ android:id="@+id/medPriority"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:checked="true"
+ android:text="@string/priority_medium_string" />
+
+ <RadioButton
+ android:id="@+id/highPriority"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="@string/priority_high_string" />
+ </RadioGroup>
+
+ <!-- Time and Date -->
+
+ <TextView
+ android:id="@+id/time_and_date"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@id/priorityGroup"
+ android:layout_marginTop="25dp"
+ android:text="@string/time_and_date_string"
+ android:textAppearance="?android:attr/textAppearanceLarge" />
+
+ <TextView
+ android:id="@+id/date"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@+id/time_and_date"
+ android:layout_marginTop="12dp"
+ android:text="@string/no_date_set_string" />
+
+ <TextView
+ android:id="@+id/time"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentRight="true"
+ android:layout_below="@+id/time_and_date"
+ android:text="@string/no_time_set_string" />
+
+ <Button
+ android:id="@+id/date_picker_button"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@id/date"
+ android:text="@string/choose_date_string" />
+
+ <Button
+ android:id="@+id/time_picker_button"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentRight="true"
+ android:layout_alignTop="@id/date_picker_button"
+ android:layout_below="@id/time"
+ android:text="@string/choose_time_string" />
+
+ <!-- Buttons -->
+
+ <Button
+ android:id="@+id/cancelButton"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentBottom="true"
+ android:layout_alignParentLeft="true"
+ android:layout_marginTop="25dp"
+ android:text="@string/cancel_string" />
+
+ <Button
+ android:id="@+id/resetButton"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentBottom="true"
+ android:layout_centerHorizontal="true"
+ android:text="@string/reset_string" />
+
+ <Button
+ android:id="@+id/submitButton"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentBottom="true"
+ android:layout_alignParentRight="true"
+ android:text="@string/submit_string" />
+
+</RelativeLayout>
diff --git a/Android/05-UserInterface/UILab/res/layout/footer_view.xml b/Android/05-UserInterface/UILab/res/layout/footer_view.xml
new file mode 100644
index 0000000..311856f
--- /dev/null
+++ b/Android/05-UserInterface/UILab/res/layout/footer_view.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="utf-8"?>
+<TextView xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/footerView"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:gravity="center_horizontal"
+ android:text="@string/add_new_todo_item_string"
+ android:textSize="24sp" >
+
+</TextView> \ No newline at end of file
diff --git a/Android/05-UserInterface/UILab/res/layout/todo_item.xml b/Android/05-UserInterface/UILab/res/layout/todo_item.xml
new file mode 100644
index 0000000..44ef9fc
--- /dev/null
+++ b/Android/05-UserInterface/UILab/res/layout/todo_item.xml
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="utf-8"?>
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/RelativeLayout1"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical" >
+
+ <TextView
+ android:id="@+id/titleView"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_alignParentTop="true"
+ android:textAppearance="?android:attr/textAppearanceLarge" >
+ </TextView>
+
+ <TextView
+ android:id="@+id/StatusLabel"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignBaseline="@+id/statusCheckBox"
+ android:layout_alignParentLeft="true"
+ android:layout_alignParentTop="true"
+ android:layout_marginTop="17dp"
+ android:text="@string/done_string" >
+ </TextView>
+
+ <CheckBox
+ android:id="@+id/statusCheckBox"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentTop="true"
+ android:layout_marginTop="52dp"
+ android:layout_toRightOf="@+id/StatusLabel" >
+ </CheckBox>
+
+ <TextView
+ android:id="@+id/PriorityLabel"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignBaseline="@+id/statusCheckBox"
+ android:layout_alignTop="@+id/StatusLabel"
+ android:layout_toLeftOf="@+id/priorityView"
+ android:text="@string/priority_string" >
+ </TextView>
+
+ <TextView
+ android:id="@+id/priorityView"
+ android:layout_width="50dip"
+ android:layout_height="wrap_content"
+ android:layout_alignBaseline="@+id/statusCheckBox"
+ android:layout_alignParentRight="true"
+ android:layout_alignTop="@+id/StatusLabel" >
+ </TextView>
+
+ <TextView
+ android:id="@+id/DateLabel"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentLeft="true"
+ android:layout_below="@+id/statusCheckBox"
+ android:text="@string/date_string" >
+ </TextView>
+
+ <TextView
+ android:id="@+id/dateView"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignBaseline="@+id/DateLabel"
+ android:layout_toRightOf="@+id/DateLabel" >
+ </TextView>
+
+</RelativeLayout> \ No newline at end of file