title: Problems updating very simple appwidget
body: <p>I've been following <a href="http://www.helloandroid.com/files/xmaswidget/android_howto-hellowidget.pdf" rel="nofollow">this</a> tutorial trying to make a very simple clock widget for android. I'm able to create the widget, but it does not seem to update. I find this very strange as my code seems to be essentially what the same as <a href="http://android-developers.blogspot.com/2009/04/introducing-home-screen-widgets-and.html" rel="nofollow">tutorial</a> at the android dev blog does. </p>
  
  <p>When I add the widget to the home screen (Android 2.2 emulator) I get the following messages in logCat:</p>
  
  <pre><code>I/ActivityManager(   68): Starting activity: Intent { act=android.appwidget.action.APPWIDGET_PICK cmp=com.android.settings/.AppWidgetPickActivity (has extras) }
  W/InputManagerService(   68): Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy@44fbaf40
  I/AppWidgetPickActivity(  135): EXTRA_CUSTOM_INFO not present.
  I/ActivityManager(   68): Displayed activity com.android.settings/.AppWidgetPickActivity: 1181 ms (total 1181 ms)
  W/ActivityManager(   68): Unable to launch app com.levold.customClockWidget/10036 for broadcast Intent { act=android.appwidget.action.APPWIDGET_ENABLED cmp=com.levold.customClockWidget/.ClockWidget }: process is bad
  W/ActivityManager(   68): finishReceiver called but none active
  W/ActivityManager(   68): Unable to launch app com.levold.customClockWidget/10036 for broadcast Intent { act=android.appwidget.action.APPWIDGET_UPDATE cmp=com.levold.customClockWidget/.ClockWidget (has extras) }: process is bad
  W/ActivityManager(   68): finishReceiver called but none active
  W/InputManagerService(   68): Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy@44fe1c50
  </code></pre>
  
  <p>The lines <code>Unable to launch app com.levold.customClockWidget/10036 for broadcast Intent { act=android.appwidget.action.APPWIDGET_ENABLED cmp=com.levold.customClockWidget/.ClockWidget }: process is bad</code> seems to be the most relevant here, but I haven't been able to find much info about it.</p>
  
  <p>Most of the code is below. If anybody could help that would be absolutely great, I'm pretty much stuck at the moment...</p>
  
  <p><strong>AndroidManifest.xml</strong></p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;manifest xmlns:android="http://schemas.android.com/apk/res/android"
        package="com.levold.customClockWidget"
        android:versionCode="1"
        android:versionName="1.0"&gt;
  
    &lt;application android:icon="@drawable/icon" android:label="@string/app_name"&gt;
  
      &lt;!-- Broadcast Receiver that will process AppWidget updates --&gt;
      &lt;receiver android:name=".ClockWidget" android:label="@string/app_name"&gt;
          &lt;intent-filter&gt;
              &lt;action android:name="android.appwidget.action.APPWIDGET_UPDATE" /&gt;
          &lt;/intent-filter&gt;
          &lt;meta-data android:name="android.appwidget.provider" android:resource="@xml/custom_clock_widget" /&gt;
      &lt;/receiver&gt;
  
      &lt;/application&gt;
  &lt;/manifest&gt;
  </code></pre>
  
  <p><strong>xml/custom_clock_widget.xml</strong></p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"
      android:minWidth="146dip"
      android:minHeight="72dip"
      android:updatePeriodMillis="1000"
      android:initialLayout="@layout/main"
  /&gt;
  </code></pre>
  
  <p><strong>src/com/levold/customClockWidget/ClockWidget.java</strong></p>
  
  <pre><code>package com.levold.customClockWidget;
  
  import android.appwidget.AppWidgetManager;
  import android.appwidget.AppWidgetProvider;
  import android.content.Context;
  import android.util.Log;
  import android.widget.Toast;
  
  public class ClockWidget extends AppWidgetProvider {
  
      @Override
      public void onUpdate(Context context, AppWidgetManager appWidgetManager, int[] appWidgetIds) {
          Toast.makeText(context,"Updating widget...", Toast.LENGTH_SHORT).show();
          Log.i("clockWidget","Updating widget...");
      }
  </code></pre>