removed old config.xml (relict from early development)

start preferences activity on push
This commit is contained in:
Ronald Schaten 2011-06-08 13:53:24 +02:00
parent 081a3cbdbc
commit 40d738a2fa
3 changed files with 6 additions and 26 deletions

View File

@ -1,26 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:orientation="vertical">
<TextView android:text="@string/name" android:layout_width="fill_parent"
android:layout_height="wrap_content" />
<EditText android:text="@string/title" android:id="@+id/name"
android:layout_width="fill_parent" android:layout_height="wrap_content" />
<TextView android:text="@string/dateThen"
android:layout_width="fill_parent" android:layout_height="wrap_content" />
<DatePicker android:layout_width="fill_parent"
android:layout_height="wrap_content" android:id="@+id/dateThen">
</DatePicker>
<LinearLayout android:id="@+id/LinearLayout01"
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:orientation="horizontal">
<Button android:layout_width="fill_parent"
android:layout_height="wrap_content" android:id="@+id/okbutton"
android:text="OK"></Button>
<Button android:layout_width="fill_parent"
android:layout_height="wrap_content" android:text="Cancel"
android:id="@+id/cancelbutton"></Button>
</LinearLayout>
</LinearLayout>

View File

@ -29,4 +29,5 @@
android:textColor="@android:color/white" android:text="debug"
android:textSize="4pt" />
</LinearLayout>

View File

@ -82,6 +82,11 @@ public class WaldemarWidget extends AppWidgetProvider {
AppWidgetManager appWidgetManager, int appWidgetId) {
RemoteViews remoteViews = new RemoteViews(context.getPackageName(), R.layout.main);
// Create an Intent to launch PreferenceActivity
Intent intent = new Intent(context, WaldemarPreferences.class);
PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent, 0);
remoteViews.setOnClickPendingIntent(R.id.daycount, pendingIntent);
DateFormat format = SimpleDateFormat.getTimeInstance(
SimpleDateFormat.MEDIUM, Locale.getDefault());
remoteViews.setTextViewText(R.id.debug, format.format(new Date()));