diff options
author | Dianne Hackborn <hackbod@google.com> | 2011-04-12 18:16:08 -0700 |
---|---|---|
committer | Dianne Hackborn <hackbod@google.com> | 2011-04-12 18:28:06 -0700 |
commit | 0c5001d776d56bae02a5cc2663286a125d99bc5e (patch) | |
tree | ea7458737297e313c454f18d672e2b997af13990 /core/java/android/app/IActivityManager.java | |
parent | 26b05f7dc35f47bc62bf9630df288ae2d6e4657e (diff) | |
download | frameworks_base-0c5001d776d56bae02a5cc2663286a125d99bc5e.zip frameworks_base-0c5001d776d56bae02a5cc2663286a125d99bc5e.tar.gz frameworks_base-0c5001d776d56bae02a5cc2663286a125d99bc5e.tar.bz2 |
Add APIs to remove tasks.
You can remove sub-tasks inside of a task, or an entire task.
When removing an entire task, you can have its process killed
as well.
When the process is killed, any running services will get an
onTaskRemoved() callback for them to do cleanup before their
process is killed (and the service possibly restarted).
Or they can set a new android:stopWithTask attribute to just
have the service automatically (cleanly) stopped at this point.
Change-Id: I1891bc2da006fa53b99c52f9040f1145650e6808
Diffstat (limited to 'core/java/android/app/IActivityManager.java')
-rw-r--r-- | core/java/android/app/IActivityManager.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/core/java/android/app/IActivityManager.java b/core/java/android/app/IActivityManager.java index 5a15b08..bec697a 100644 --- a/core/java/android/app/IActivityManager.java +++ b/core/java/android/app/IActivityManager.java @@ -344,6 +344,10 @@ public interface IActivityManager extends IInterface { // Multi-user APIs public boolean switchUser(int userid) throws RemoteException; + + public boolean removeSubTask(int taskId, int subTaskIndex) throws RemoteException; + + public boolean removeTask(int taskId, int flags) throws RemoteException; /* * Private non-Binder interfaces @@ -561,4 +565,6 @@ public interface IActivityManager extends IInterface { int START_ACTIVITIES_IN_PACKAGE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+121; int ACTIVITY_SLEPT_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+122; int SWITCH_USER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+123; + int REMOVE_SUB_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+124; + int REMOVE_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+125; } |