oh, okay, so I added this line to my manifest --
<data android:scheme="package"/>
and it seemed to work. I get a removed followed by a replaced. as is
documented here:
http://developer.android.com/intl/fr/guide/appendix/faq/framework.html
now I just gotta figure out how to remove/replace the app widget when
i get this... anyone??
On Nov 18, 12:13 pm, sdphil <[email protected]> wrote:
> when I re-install an application, i get PACKAGE_REMOVED followed by
> PACKAGE_ADDED.
>
> I never see PACKAGE_REPLACED. any ideas why? And actually, I never
> see any of the PACKAGE_* actions except in LogCast -- I cannot get my
> broadcast receiver to get the events.
>
> i'm doing this in the emulator using adb --
>
> adb install -r MyApp.apk
>
> My Android manifest has these lines in it:
>
> <application...>
> ...
> ...
> <receiver android:name="com.test.MyApp.UpdateReceiver">
> <intent-filter>
> <action
> android:name="android.intent.action.PACKAGE_ADDED"/>
> <action
> android:name="android.intent.action.PACKAGE_REMOVED"/>
> <action
> android:name="android.intent.action.PACKAGE_REPLACED"/>
> </intent-filter>
> </receiver>
> ...
> ...
> </application>
>
> And my UpdateReceiver.java looks like this:
>
> package com.test.MyApp;
>
> import android.content.BroadcastReceiver;
> import android.content.Context;
> import android.content.Intent;
>
> public class UpdateReceiver extends BroadcastReceiver {
>
> @Override
> public void onReceive(Context context, Intent intent) {
> String action = intent.getAction();
> System.err.println("action: " + action);
> }
>
> }
>
> tia.
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en