[android-developers] power button

2012-03-04 Thread zasaz
hi everyone! how can i set password on shutdown device or on press power 
button?

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Power button

2011-12-20 Thread Jeffrey Dunbar
I am developing an app, I would like to use the power button as a
panic button. Is there a way to hook into and catch globally from a
service. I know that android fires the intent.action SCREEN_ON and
_OFF but this causes issues. I have a service that monitors for screen
on/off sets an alarm on first press to expire and reset a setting if
not hit 3 times in 1.5 seconds. There are times that this condition
can be met just by the normal power down of the screen. e.g. market is
downloading an app and screen goes to sleep, you wake up to check and
turn off the screen after checking

Any help greatly appreciated.

Jeff

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Power button

2011-12-20 Thread Mark Murphy
On Tue, Dec 20, 2011 at 12:28 PM, Jeffrey Dunbar
nightsbird.mob...@gmail.com wrote:
 I am developing an app, I would like to use the power button as a
 panic button. Is there a way to hook into and catch globally from a
 service.

No.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android App Developer Books: http://commonsware.com/books

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] power button hitting onCreate

2010-04-22 Thread scottrick49
In my application, if you press the power button on the phone, i am
seeing:

onPause
onDestroy
onCreate
onResume
onPause

getting called in that order; I can't figure out why the app is
getting created again and then re-paused.  Obviously I am doing
something incorrect, but I am not sure what.  Anybody seen anything
like this before?

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] power button hitting onCreate

2010-04-22 Thread Dianne Hackborn
When you turn off the device, the lock screen is displayed.  This typically
forces the display to a particular orientation.  If the screen is not
currently in that orientation, it will need to be changed, and the top
activity's configuration appropriately changed to match.

On Thu, Apr 22, 2010 at 1:55 PM, scottrick49 scottric...@gmail.com wrote:

 In my application, if you press the power button on the phone, i am
 seeing:

 onPause
 onDestroy
 onCreate
 onResume
 onPause

 getting called in that order; I can't figure out why the app is
 getting created again and then re-paused.  Obviously I am doing
 something incorrect, but I am not sure what.  Anybody seen anything
 like this before?

 --
 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+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en