Loading config/hiddenapi-vendor-list.txt +1 −1 Original line number Diff line number Diff line Loading @@ -20,7 +20,7 @@ Landroid/app/AppOpsManager$PackageOps;->getOps()Ljava/util/List; Landroid/app/AppOpsManager$PackageOps;->getPackageName()Ljava/lang/String; Landroid/app/AppOpsManager$PackageOps;->getUid()I Landroid/app/IActivityController$Stub;-><init>()V Landroid/app/IActivityManager;->cancelRecentsAnimation()V Landroid/app/IActivityManager;->cancelRecentsAnimation(Z)V Landroid/app/IActivityManager;->cancelTaskWindowTransition(I)V Landroid/app/IActivityManager;->closeSystemDialogs(Ljava/lang/String;)V Landroid/app/IActivityManager;->getCurrentUser()Landroid/content/pm/UserInfo; Loading core/java/android/app/IActivityManager.aidl +1 −1 Original line number Diff line number Diff line Loading @@ -450,7 +450,7 @@ interface IActivityManager { in Intent intent, in String resolvedType, in Bundle options, int userId); void startRecentsActivity(in Intent intent, in IAssistDataReceiver assistDataReceiver, in IRecentsAnimationRunner recentsAnimationRunner); void cancelRecentsAnimation(); void cancelRecentsAnimation(boolean restoreHomeStackPosition); int startActivityFromRecents(int taskId, in Bundle options); Bundle getActivityOptions(in IBinder token); List<IBinder> getAppTasks(in String callingPackage); Loading packages/SystemUI/shared/src/com/android/systemui/shared/system/ActivityManagerWrapper.java +2 −2 Original line number Diff line number Diff line Loading @@ -258,9 +258,9 @@ public class ActivityManagerWrapper { /** * Cancels the remote recents animation started from {@link #startRecentsActivity}. */ public void cancelRecentsAnimation() { public void cancelRecentsAnimation(boolean restoreHomeStackPosition) { try { ActivityManager.getService().cancelRecentsAnimation(); ActivityManager.getService().cancelRecentsAnimation(restoreHomeStackPosition); } catch (RemoteException e) { Log.e(TAG, "Failed to cancel recents animation", e); } Loading packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java +7 −2 Original line number Diff line number Diff line Loading @@ -52,6 +52,7 @@ import com.android.systemui.plugins.statusbar.phone.NavBarButtonProvider.ButtonI import com.android.systemui.shared.system.ActivityManagerWrapper; import com.android.systemui.statusbar.VibratorHelper; import static android.view.KeyEvent.KEYCODE_HOME; import static android.view.accessibility.AccessibilityNodeInfo.ACTION_CLICK; import static android.view.accessibility.AccessibilityNodeInfo.ACTION_LONG_CLICK; Loading Loading @@ -270,8 +271,12 @@ public class KeyButtonView extends ImageView implements ButtonInterface { if (mCode != 0) { if (doIt) { // If there was a pending remote recents animation, then we need to // cancel the animation now before we handle the button itself ActivityManagerWrapper.getInstance().cancelRecentsAnimation(); // cancel the animation now before we handle the button itself. In the case // where we are going home and the recents animation has already started, // just cancel the recents animation, leaving the home stack in place boolean isHomeKey = mCode == KEYCODE_HOME; ActivityManagerWrapper.getInstance().cancelRecentsAnimation(!isHomeKey); sendEvent(KeyEvent.ACTION_UP, 0); sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_CLICKED); } else { Loading services/core/java/com/android/server/am/ActivityManagerService.java +6 −3 Original line number Diff line number Diff line Loading @@ -204,6 +204,8 @@ import static android.view.WindowManager.TRANSIT_NONE; import static android.view.WindowManager.TRANSIT_TASK_IN_PLACE; import static android.view.WindowManager.TRANSIT_TASK_OPEN; import static android.view.WindowManager.TRANSIT_TASK_TO_FRONT; import static com.android.server.wm.RecentsAnimationController.REORDER_MOVE_HOME_TO_ORIGINAL_POSITION; import static com.android.server.wm.RecentsAnimationController.REORDER_KEEP_HOME_IN_PLACE; import static org.xmlpull.v1.XmlPullParser.END_DOCUMENT; import static org.xmlpull.v1.XmlPullParser.START_TAG; Loading Loading @@ -257,7 +259,6 @@ import android.app.WaitResult; import android.app.WindowConfiguration.ActivityType; import android.app.WindowConfiguration.WindowingMode; import android.app.admin.DevicePolicyCache; import android.app.admin.DevicePolicyManager; import android.app.assist.AssistContent; import android.app.assist.AssistStructure; import android.app.backup.IBackupManager; Loading Loading @@ -5238,12 +5239,14 @@ public class ActivityManagerService extends IActivityManager.Stub } @Override public void cancelRecentsAnimation() { public void cancelRecentsAnimation(boolean restoreHomeStackPosition) { enforceCallerIsRecentsOrHasPermission(MANAGE_ACTIVITY_STACKS, "cancelRecentsAnimation()"); final long origId = Binder.clearCallingIdentity(); try { synchronized (this) { mWindowManager.cancelRecentsAnimation(); mWindowManager.cancelRecentsAnimation(restoreHomeStackPosition ? REORDER_MOVE_HOME_TO_ORIGINAL_POSITION : REORDER_KEEP_HOME_IN_PLACE); } } finally { Binder.restoreCallingIdentity(origId); Loading
config/hiddenapi-vendor-list.txt +1 −1 Original line number Diff line number Diff line Loading @@ -20,7 +20,7 @@ Landroid/app/AppOpsManager$PackageOps;->getOps()Ljava/util/List; Landroid/app/AppOpsManager$PackageOps;->getPackageName()Ljava/lang/String; Landroid/app/AppOpsManager$PackageOps;->getUid()I Landroid/app/IActivityController$Stub;-><init>()V Landroid/app/IActivityManager;->cancelRecentsAnimation()V Landroid/app/IActivityManager;->cancelRecentsAnimation(Z)V Landroid/app/IActivityManager;->cancelTaskWindowTransition(I)V Landroid/app/IActivityManager;->closeSystemDialogs(Ljava/lang/String;)V Landroid/app/IActivityManager;->getCurrentUser()Landroid/content/pm/UserInfo; Loading
core/java/android/app/IActivityManager.aidl +1 −1 Original line number Diff line number Diff line Loading @@ -450,7 +450,7 @@ interface IActivityManager { in Intent intent, in String resolvedType, in Bundle options, int userId); void startRecentsActivity(in Intent intent, in IAssistDataReceiver assistDataReceiver, in IRecentsAnimationRunner recentsAnimationRunner); void cancelRecentsAnimation(); void cancelRecentsAnimation(boolean restoreHomeStackPosition); int startActivityFromRecents(int taskId, in Bundle options); Bundle getActivityOptions(in IBinder token); List<IBinder> getAppTasks(in String callingPackage); Loading
packages/SystemUI/shared/src/com/android/systemui/shared/system/ActivityManagerWrapper.java +2 −2 Original line number Diff line number Diff line Loading @@ -258,9 +258,9 @@ public class ActivityManagerWrapper { /** * Cancels the remote recents animation started from {@link #startRecentsActivity}. */ public void cancelRecentsAnimation() { public void cancelRecentsAnimation(boolean restoreHomeStackPosition) { try { ActivityManager.getService().cancelRecentsAnimation(); ActivityManager.getService().cancelRecentsAnimation(restoreHomeStackPosition); } catch (RemoteException e) { Log.e(TAG, "Failed to cancel recents animation", e); } Loading
packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java +7 −2 Original line number Diff line number Diff line Loading @@ -52,6 +52,7 @@ import com.android.systemui.plugins.statusbar.phone.NavBarButtonProvider.ButtonI import com.android.systemui.shared.system.ActivityManagerWrapper; import com.android.systemui.statusbar.VibratorHelper; import static android.view.KeyEvent.KEYCODE_HOME; import static android.view.accessibility.AccessibilityNodeInfo.ACTION_CLICK; import static android.view.accessibility.AccessibilityNodeInfo.ACTION_LONG_CLICK; Loading Loading @@ -270,8 +271,12 @@ public class KeyButtonView extends ImageView implements ButtonInterface { if (mCode != 0) { if (doIt) { // If there was a pending remote recents animation, then we need to // cancel the animation now before we handle the button itself ActivityManagerWrapper.getInstance().cancelRecentsAnimation(); // cancel the animation now before we handle the button itself. In the case // where we are going home and the recents animation has already started, // just cancel the recents animation, leaving the home stack in place boolean isHomeKey = mCode == KEYCODE_HOME; ActivityManagerWrapper.getInstance().cancelRecentsAnimation(!isHomeKey); sendEvent(KeyEvent.ACTION_UP, 0); sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_CLICKED); } else { Loading
services/core/java/com/android/server/am/ActivityManagerService.java +6 −3 Original line number Diff line number Diff line Loading @@ -204,6 +204,8 @@ import static android.view.WindowManager.TRANSIT_NONE; import static android.view.WindowManager.TRANSIT_TASK_IN_PLACE; import static android.view.WindowManager.TRANSIT_TASK_OPEN; import static android.view.WindowManager.TRANSIT_TASK_TO_FRONT; import static com.android.server.wm.RecentsAnimationController.REORDER_MOVE_HOME_TO_ORIGINAL_POSITION; import static com.android.server.wm.RecentsAnimationController.REORDER_KEEP_HOME_IN_PLACE; import static org.xmlpull.v1.XmlPullParser.END_DOCUMENT; import static org.xmlpull.v1.XmlPullParser.START_TAG; Loading Loading @@ -257,7 +259,6 @@ import android.app.WaitResult; import android.app.WindowConfiguration.ActivityType; import android.app.WindowConfiguration.WindowingMode; import android.app.admin.DevicePolicyCache; import android.app.admin.DevicePolicyManager; import android.app.assist.AssistContent; import android.app.assist.AssistStructure; import android.app.backup.IBackupManager; Loading Loading @@ -5238,12 +5239,14 @@ public class ActivityManagerService extends IActivityManager.Stub } @Override public void cancelRecentsAnimation() { public void cancelRecentsAnimation(boolean restoreHomeStackPosition) { enforceCallerIsRecentsOrHasPermission(MANAGE_ACTIVITY_STACKS, "cancelRecentsAnimation()"); final long origId = Binder.clearCallingIdentity(); try { synchronized (this) { mWindowManager.cancelRecentsAnimation(); mWindowManager.cancelRecentsAnimation(restoreHomeStackPosition ? REORDER_MOVE_HOME_TO_ORIGINAL_POSITION : REORDER_KEEP_HOME_IN_PLACE); } } finally { Binder.restoreCallingIdentity(origId);