Is there any way for a 3rd party app to get notified when
startActivity has been called (from any app or the framework)?

My specific need is to keep track of the number of times activities
have been launched from my 3rd party app... I just need to know when
startActivity has been called to launch a new screen, and then I'd
like to also read the FLAG_ACTIVITY_LAUNCHED_FROM_HISTORY flag that is
set when an app is launched from the recent apps dialog:

>From frameworks/policies/base/phone/com/android/internal/policy/impl/
RecentApplicationsDialog.java ...

               // prepare a launch intent and send it
                Intent intent = (Intent)b.getTag();
 
intent.addFlags(Intent.FLAG_ACTIVITY_LAUNCHED_FROM_HISTORY);
                getContext().startActivity(intent);

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