Why do you need to know if Home was hit?
There probably is no obvious way because there is no obvious need. Thanks. On Friday, April 5, 2013 1:27:58 PM UTC-5, disha wrote: > > But those will be invoked when app starts another activity,dialog or any > pop up window. I know there are couple of ways to do it. Like onPause() > check the activity stack for number of activities in it.If it has only one > activity, in that case we can consider app is going to background. > > > On Fri, Apr 5, 2013 at 12:12 PM, RichardC > <[email protected]<javascript:> > > wrote: > >> You already get 2 callbacks >> Activity.onPause() >> Activity.onStop() >> >> What else do you need ? >> >> >> On Friday, April 5, 2013 5:27:10 PM UTC+1, disha wrote: >>> >>> Hi, >>> >>> I want to fire an event when android app goes into background like by >>> pressing home key button on device. Is there any better way to do this? >>> >>> Thanks >>> >> -- >> -- >> 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]<javascript:> >> To unsubscribe from this group, send email to >> [email protected] <javascript:> >> For more options, visit this group at >> http://groups.google.com/group/android-developers?hl=en >> --- >> You received this message because you are subscribed to the Google Groups >> "Android Developers" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/groups/opt_out. >> >> >> > > -- -- 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 --- You received this message because you are subscribed to the Google Groups "Android Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.

