Is possible to get full app screenshot from "Recent opened apps"?
I want to make MeeGo or Symbian similar task manager for Android.
I doubt this is possible without running on a rooted phone.
The system recent tasks panel gets the thumbnails via this code:
final ActivityManager am = (ActivityManager)
mContext.getSystemService(Context.ACTIVITY_SERVICE);
ActivityManager.TaskThumbnails thumbs = am.getTaskThumbnails(td.persistentTaskId);
But it seems getTaskThumbnails
is a private method and only allowed to be accessed with system privileges.
Another option would be to use ActivityManager.getRunningTaks()
to get the list of running tasks, then use RunningTaskInfo.thumbnail
to get a thumbnail of the app. However, it seems that always returns null.
You could get the list of running tasks using AvtivityManager.getRunningTasks and use this to take the screenshots. Refer this project: http://androidexample.com/Check_Current_Running_Activity_%7C_Task_%7C_Application_-_Android_Example/index.php?view=article_discription&aid=111&aaid=133
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.