Saturday, July 3, 2010

[android-developers] How to handle SCREEN_OFF/_ON intents

Hi All,

I'm trying to handle the events SCREEN_OFF and _ON when the device
going to sleep mode.
I tried creating the broadcast receivers registering in the manifest
by using <receiver> tag, and also tried using the registerReceiver()
in a background running service, to get notified in all the times.
But I couldn't receive any intent in my onReceive of both the cases.

I want to display a dialog before the device is going to sleep mode.

I tried creating the same in onReceive(), but I'm not getting the
control to this place, when device is going to sleep mode.

Could you please help me in solving this? Can you give me some
suggestions, how it is working for you???

- Durga

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate