Merge "Moving recent tasks information to a user directory"
This commit is contained in:
committed by
Android (Google) Code Review
commit
d93d481ea1
@@ -884,7 +884,7 @@ public class ActivityManager {
|
||||
if (mIcon != null) {
|
||||
return mIcon;
|
||||
}
|
||||
return loadTaskDescriptionIcon(mIconFilename);
|
||||
return loadTaskDescriptionIcon(mIconFilename, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
@@ -898,11 +898,11 @@ public class ActivityManager {
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static Bitmap loadTaskDescriptionIcon(String iconFilename) {
|
||||
public static Bitmap loadTaskDescriptionIcon(String iconFilename, int userId) {
|
||||
if (iconFilename != null) {
|
||||
try {
|
||||
return ActivityManagerNative.getDefault().
|
||||
getTaskDescriptionIcon(iconFilename);
|
||||
getTaskDescriptionIcon(iconFilename, userId);
|
||||
} catch (RemoteException e) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2490,7 +2490,8 @@ public abstract class ActivityManagerNative extends Binder implements IActivityM
|
||||
case GET_TASK_DESCRIPTION_ICON_TRANSACTION: {
|
||||
data.enforceInterface(IActivityManager.descriptor);
|
||||
String filename = data.readString();
|
||||
Bitmap icon = getTaskDescriptionIcon(filename);
|
||||
int userId = data.readInt();
|
||||
Bitmap icon = getTaskDescriptionIcon(filename, userId);
|
||||
reply.writeNoException();
|
||||
if (icon == null) {
|
||||
reply.writeInt(0);
|
||||
@@ -5998,11 +5999,12 @@ class ActivityManagerProxy implements IActivityManager
|
||||
}
|
||||
|
||||
@Override
|
||||
public Bitmap getTaskDescriptionIcon(String filename) throws RemoteException {
|
||||
public Bitmap getTaskDescriptionIcon(String filename, int userId) throws RemoteException {
|
||||
Parcel data = Parcel.obtain();
|
||||
Parcel reply = Parcel.obtain();
|
||||
data.writeInterfaceToken(IActivityManager.descriptor);
|
||||
data.writeString(filename);
|
||||
data.writeInt(userId);
|
||||
mRemote.transact(GET_TASK_DESCRIPTION_ICON_TRANSACTION, data, reply, 0);
|
||||
reply.readException();
|
||||
final Bitmap icon = reply.readInt() == 0 ? null : Bitmap.CREATOR.createFromParcel(reply);
|
||||
|
||||
@@ -497,7 +497,7 @@ public interface IActivityManager extends IInterface {
|
||||
public void resizeTask(int taskId, Rect bounds, int resizeMode) throws RemoteException;
|
||||
|
||||
public Rect getTaskBounds(int taskId) throws RemoteException;
|
||||
public Bitmap getTaskDescriptionIcon(String filename) throws RemoteException;
|
||||
public Bitmap getTaskDescriptionIcon(String filename, int userId) throws RemoteException;
|
||||
|
||||
public void startInPlaceAnimationOnFrontMostApplication(ActivityOptions opts)
|
||||
throws RemoteException;
|
||||
|
||||
Reference in New Issue
Block a user