Dump out last real used app transit type
Easier for debugging or testing bad exit animations.
Bug: 30790402
Bug: 30255354
Change-Id: I8097195bfc918baf66ecc99b55f4845aba2eaff4
(cherry picked from commit 1c93f6de2d)
This commit is contained in:
committed by
Wale Ogunwale
parent
eed326b072
commit
60091a978f
@@ -162,6 +162,9 @@ public class AppTransition implements Dump {
|
||||
private final WindowManagerService mService;
|
||||
|
||||
private int mNextAppTransition = TRANSIT_UNSET;
|
||||
private int mLastUsedAppTransition = TRANSIT_UNSET;
|
||||
private String mLastOpeningApp;
|
||||
private String mLastClosingApp;
|
||||
|
||||
private static final int NEXT_TRANSIT_TYPE_NONE = 0;
|
||||
private static final int NEXT_TRANSIT_TYPE_CUSTOM = 1;
|
||||
@@ -285,6 +288,13 @@ public class AppTransition implements Dump {
|
||||
|
||||
private void setAppTransition(int transit) {
|
||||
mNextAppTransition = transit;
|
||||
setLastAppTransition(TRANSIT_UNSET, null, null);
|
||||
}
|
||||
|
||||
void setLastAppTransition(int transit, AppWindowToken openingApp, AppWindowToken closingApp) {
|
||||
mLastUsedAppTransition = transit;
|
||||
mLastOpeningApp = "" + openingApp;
|
||||
mLastClosingApp = "" + closingApp;
|
||||
}
|
||||
|
||||
boolean isReady() {
|
||||
@@ -1904,6 +1914,14 @@ public class AppTransition implements Dump {
|
||||
pw.print(prefix); pw.print("mNextAppTransitionCallback=");
|
||||
pw.println(mNextAppTransitionCallback);
|
||||
}
|
||||
if (mLastUsedAppTransition != TRANSIT_NONE) {
|
||||
pw.print(prefix); pw.print("mLastUsedAppTransition=");
|
||||
pw.println(appTransitionToString(mLastUsedAppTransition));
|
||||
pw.print(prefix); pw.print("mLastOpeningApp=");
|
||||
pw.println(mLastOpeningApp);
|
||||
pw.print(prefix); pw.print("mLastClosingApp=");
|
||||
pw.println(mLastClosingApp);
|
||||
}
|
||||
}
|
||||
|
||||
public void setCurrentUser(int newUserId) {
|
||||
|
||||
@@ -1189,6 +1189,8 @@ class WindowSurfacePlacer {
|
||||
final AppWindowToken topOpeningApp = handleOpeningApps(transit,
|
||||
animLp, voiceInteraction, topClosingLayer);
|
||||
|
||||
mService.mAppTransition.setLastAppTransition(transit, topOpeningApp, topClosingApp);
|
||||
|
||||
final AppWindowAnimator openingAppAnimator = (topOpeningApp == null) ? null :
|
||||
topOpeningApp.mAppAnimator;
|
||||
final AppWindowAnimator closingAppAnimator = (topClosingApp == null) ? null :
|
||||
|
||||
Reference in New Issue
Block a user