Hi Mark,

Thanks for the reply. You are right , I could have used onResume in
my secondary(not root activity) activities, but onResume will be called
 even when I navigate between the activities in my app once it is launched.
. I dont want to check the user token during this scenario as it would be a
overkill.

My requirement is if my application( hint app task level) as a whole is
brought to foreground ( see the two cases below)

a) From the Home page - works fine in this scenario
b) From the Recent Apps - has the issue , here i cant know the onResume for
any secondary activity  is called due to an internal navigation or due to
the *app task* coming to the foreground again. So i thought of using the
FLAG_ACTIVITY_LAUNCHED_FROM_HISTORY<http://developer.android.com/reference/android/content/Intent.html#FLAG_ACTIVITY_LAUNCHED_FROM_HISTORY>
 from any of the secondary activity but I get 0 when I query for getFlags()
in any of the secondary activity

thanks
And Uzer

On Sat, Apr 30, 2011 at 7:54 PM, Mark Murphy <[email protected]>wrote:

> On Sat, Apr 30, 2011 at 10:15 AM, Manohar Mahapatra
> <[email protected]> wrote:
> > My application is a client based financial app and compulsorily it needs
> to
> > validate the user token from the server every time it comes to
> foreground.
> > This is a security mandate.
>
> Then validate the user token in every activity in onResume(). I fail
> to see how anything else can satisfy this "security mandate".
>
> Android applications don't "come to foreground" any more than Web
> applications do.
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
>
> _The Busy Coder's Guide to Android Development_ Version 3.6 Available!
>
> --
> 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 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