I know I can get recent tasks list by using
ActivityManager - public List<RecentTaskInfo> getRecentTasks(int
maxNum, int flags);
but can I modfiy it?
I also check the source code to find out the storage of recent tasks.
but I cannot understand it. Where the recent tasks from?
I want to add a method setRecentTasks to ActivityManagerNative.java
ActivityManagerNative.java
public List<ActivityManager.RecentTaskInfo> getRecentTasks(int
maxNum,
int flags) throws RemoteException {
Parcel data = Parcel.obtain();
Parcel reply = Parcel.obtain();
data.writeInterfaceToken(IActivityManager.descriptor);
data.writeInt(maxNum);
data.writeInt(flags);
mRemote.transact(GET_RECENT_TASKS_TRANSACTION, data, reply,
0);
reply.readException();
ArrayList<ActivityManager.RecentTaskInfo> list
= reply.createTypedArrayList
(ActivityManager.RecentTaskInfo.CREATOR);
data.recycle();
reply.recycle();
return list;
}
--
unsubscribe: [email protected]
website: http://groups.google.com/group/android-porting