android:layout_height="match_parent"
android:orientation="vertical" >
- <ScrollView
- android:id="@+id/scrollView1"
+ <TabHost
+ android:id="@android:id/tabhost"
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_weight="1.00" >
+ android:layout_height="match_parent" >
<LinearLayout
android:layout_width="match_parent"
- android:layout_height="wrap_content"
+ android:layout_height="match_parent"
android:orientation="vertical" >
- <LinearLayout
+ <TabWidget
+ android:id="@android:id/tabs"
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_weight="2.13" >
+ android:layout_height="wrap_content" >
+ </TabWidget>
- <TextView
- android:id="@+id/textView1"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="@string/title"
- android:textAppearance="?android:attr/textAppearanceMedium" />
-
- <EditText
- android:id="@+id/editText1"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:ems="10" >
-
- <requestFocus />
- </EditText>
-
- </LinearLayout>
-
- <TextView
- android:id="@+id/location"
+ <FrameLayout
+ android:id="@android:id/tabcontent"
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:text="@string/description"
- android:textAppearance="?android:attr/textAppearanceMedium" />
+ android:layout_height="match_parent" >
- <EditText
- android:id="@+id/editText2"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_weight="2.13"
- android:ems="10"
- android:inputType="textMultiLine" />
-
- <LinearLayout
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_weight="2.13" >
-
- <CheckBox
- android:id="@+id/checkBox1"
- android:layout_width="0dip"
- android:layout_height="wrap_content"
- android:layout_weight="2.13"
- android:text="@string/repeatlabel" />
-
- <Spinner
- android:id="@+id/spinner1"
- android:layout_width="213dp"
- android:layout_height="wrap_content" />
+ <LinearLayout
+ android:id="@+id/tab1"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical" >
+ </LinearLayout>
- </LinearLayout>
+ <LinearLayout
+ android:id="@+id/tab2"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical" >
+ </LinearLayout>
+ <LinearLayout
+ android:id="@+id/tab3"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical" >
+ </LinearLayout>
+ </FrameLayout>
</LinearLayout>
-
- </ScrollView>
-
- <LinearLayout
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_weight="1.00" >
-
- <TextView
- android:id="@+id/textView3"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="@string/locationlabel"
- android:textAppearance="?android:attr/textAppearanceMedium" />
-
- <EditText
- android:id="@+id/editText3"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:ems="10" />
-
- </LinearLayout>
-
- <Button
- android:id="@+id/AddEventButton"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:text="@string/addeventtitle"
- />
+ </TabHost>
</LinearLayout>
\ No newline at end of file
final Date end=new Date(e.dtend);
final SimpleDateFormat dateFormat = new SimpleDateFormat("MM/dd/yyyy", Locale.UK);
final SimpleDateFormat timeFormat = new SimpleDateFormat("HH:mm:ss", Locale.UK);
- final SimpleDateFormat dayOfWeekFormat = new SimpleDateFormat("E", Locale.UK);
+ final SimpleDateFormat dayOfWeekFormat = new SimpleDateFormat("EEEEEEE", Locale.UK);
startDay.setText(dayOfWeekFormat.format(start));
- if(dayOfWeekFormat.format(start)!=dayOfWeekFormat.format(end))
+ if(dateFormat.format(start)!=dateFormat.format(end)) {
endDay.setText(dayOfWeekFormat.format(end));
- startDate.setText(dateFormat.format(start));
- if(dateFormat.format(start)!=dateFormat.format(end))
endDate.setText(dateFormat.format(end));
+ }
+ startDate.setText(dateFormat.format(start));
startTime.setText(timeFormat.format(start));
endTime.setText(timeFormat.format(end));
}