android - How to measure time elapsed of another app? (in low memory situations) -


i making application launches games (apps not made me), , have measure time elapsed of each game session business requirement.

however, app killed if large game launch , low memory occurs.

i have tried start long-running service, runs handler monitoring package name of foreground activity, , keep service running @ least long game launched returning start_sticky, using startforeground(), running on separate process, no luck.

i tried send broadcast in ondestory(), not called.

i have platform signature , can have app run system app adding android:shareduserid="android.uid.system", help?

or there better approach measurement? thanks!


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -