summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI/src/com/android/systemui/recent
diff options
context:
space:
mode:
authorAmith Yamasani <yamasani@google.com>2012-08-03 13:09:11 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2012-08-08 16:52:53 -0700
commit8264408f5995534f8e3147b001664ea0df52aaa5 (patch)
treee6e963d2ec701047872bf641b28888a93c7b866a /packages/SystemUI/src/com/android/systemui/recent
parentfb11ffa2a04f0a6b1291cd7ffc68032fcc322312 (diff)
downloadframeworks_base-8264408f5995534f8e3147b001664ea0df52aaa5.zip
frameworks_base-8264408f5995534f8e3147b001664ea0df52aaa5.tar.gz
frameworks_base-8264408f5995534f8e3147b001664ea0df52aaa5.tar.bz2
Start the correct settings from the status bar.
Added a new method to Context: startActivityAsUser() requiring the INTERACT_ACROSS_USERS_FULL permission. Show the correct Recents list, based on current user. Added a getRecentTasksForUser() in ActivityManager. Hidden and requires the INTERACT_ACROSS_USERS_FULL permission. Change-Id: If5b56465efdd3ead36601a3b51ed4af157bbf35c
Diffstat (limited to 'packages/SystemUI/src/com/android/systemui/recent')
-rw-r--r--packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java b/packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java
index fefd0e8..3e03f85 100644
--- a/packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java
+++ b/packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java
@@ -30,6 +30,7 @@ import android.graphics.drawable.Drawable;
import android.os.AsyncTask;
import android.os.Handler;
import android.os.Process;
+import android.os.UserId;
import android.util.Log;
import com.android.systemui.R;
@@ -243,7 +244,8 @@ public class RecentTasksLoader {
mContext.getSystemService(Context.ACTIVITY_SERVICE);
final List<ActivityManager.RecentTaskInfo> recentTasks =
- am.getRecentTasks(MAX_TASKS, ActivityManager.RECENT_IGNORE_UNAVAILABLE);
+ am.getRecentTasksForUser(MAX_TASKS,
+ ActivityManager.RECENT_IGNORE_UNAVAILABLE, UserId.USER_CURRENT);
int numTasks = recentTasks.size();
ActivityInfo homeInfo = new Intent(Intent.ACTION_MAIN)
.addCategory(Intent.CATEGORY_HOME).resolveActivityInfo(pm, 0);