PendingIntent's come in several flavors: if you don't want to launch an activity, don't create one with PendingIntent.getActivity(). Rather, use PendingIntent.getBroadcast() to target a broadcast receiver (that doesn't have a UI).

-- Kostya

02.05.2011 17:55, Boozel пишет:
Hi
I'm trying to use a widget with a button which will change the value of a shared preference and show a toast when pressed? How can i just implement a method when a button on a widget is pressed and not launch a new activity.
I can only find setOnClickPendingIntent
I would like the home screnn to stay open.

Thanks for any help.


--
Kostya Vasilyev -- http://kmansoft.wordpress.com

--
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

Reply via email to