Merge "Log PiP protolog to logcat" into udc-dev am: ebf1d772a3 am: 8b5968233e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/23220291 Change-Id: I53f572e7a818c509465f35910df21fc264b55f58 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -64,7 +64,6 @@ import android.content.res.Configuration;
|
|||||||
import android.graphics.Rect;
|
import android.graphics.Rect;
|
||||||
import android.os.RemoteException;
|
import android.os.RemoteException;
|
||||||
import android.os.SystemProperties;
|
import android.os.SystemProperties;
|
||||||
import android.util.Log;
|
|
||||||
import android.view.Choreographer;
|
import android.view.Choreographer;
|
||||||
import android.view.Display;
|
import android.view.Display;
|
||||||
import android.view.Surface;
|
import android.view.Surface;
|
||||||
@@ -109,7 +108,6 @@ import java.util.function.IntConsumer;
|
|||||||
public class PipTaskOrganizer implements ShellTaskOrganizer.TaskListener,
|
public class PipTaskOrganizer implements ShellTaskOrganizer.TaskListener,
|
||||||
DisplayController.OnDisplaysChangedListener, ShellTaskOrganizer.FocusListener {
|
DisplayController.OnDisplaysChangedListener, ShellTaskOrganizer.FocusListener {
|
||||||
private static final String TAG = PipTaskOrganizer.class.getSimpleName();
|
private static final String TAG = PipTaskOrganizer.class.getSimpleName();
|
||||||
private static final boolean DEBUG = false;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The fixed start delay in ms when fading out the content overlay from bounds animation.
|
* The fixed start delay in ms when fading out the content overlay from bounds animation.
|
||||||
@@ -1045,7 +1043,8 @@ public class PipTaskOrganizer implements ShellTaskOrganizer.TaskListener,
|
|||||||
void onExitPipFinished(TaskInfo info) {
|
void onExitPipFinished(TaskInfo info) {
|
||||||
if (mLeash == null) {
|
if (mLeash == null) {
|
||||||
// TODO(239461594): Remove once the double call to onExitPipFinished() is fixed
|
// TODO(239461594): Remove once the double call to onExitPipFinished() is fixed
|
||||||
Log.w(TAG, "Warning, onExitPipFinished() called multiple times in the same sessino");
|
ProtoLog.w(ShellProtoLogGroup.WM_SHELL_PICTURE_IN_PICTURE,
|
||||||
|
"Warning, onExitPipFinished() called multiple times in the same session");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1134,15 +1133,13 @@ public class PipTaskOrganizer implements ShellTaskOrganizer.TaskListener,
|
|||||||
&& (mPipTransitionState.getTransitionState() != PipTransitionState.ENTERED_PIP);
|
&& (mPipTransitionState.getTransitionState() != PipTransitionState.ENTERED_PIP);
|
||||||
if ((mPipTransitionState.getInSwipePipToHomeTransition()
|
if ((mPipTransitionState.getInSwipePipToHomeTransition()
|
||||||
|| waitForFixedRotationOnEnteringPip) && fromRotation) {
|
|| waitForFixedRotationOnEnteringPip) && fromRotation) {
|
||||||
if (DEBUG) {
|
ProtoLog.d(ShellProtoLogGroup.WM_SHELL_PICTURE_IN_PICTURE,
|
||||||
ProtoLog.d(ShellProtoLogGroup.WM_SHELL_PICTURE_IN_PICTURE,
|
"%s: Skip onMovementBoundsChanged on rotation change"
|
||||||
"%s: Skip onMovementBoundsChanged on rotation change"
|
+ " InSwipePipToHomeTransition=%b"
|
||||||
+ " InSwipePipToHomeTransition=%b"
|
+ " mWaitForFixedRotation=%b"
|
||||||
+ " mWaitForFixedRotation=%b"
|
+ " getTransitionState=%d", TAG,
|
||||||
+ " getTransitionState=%d", TAG,
|
mPipTransitionState.getInSwipePipToHomeTransition(), mWaitForFixedRotation,
|
||||||
mPipTransitionState.getInSwipePipToHomeTransition(), mWaitForFixedRotation,
|
mPipTransitionState.getTransitionState());
|
||||||
mPipTransitionState.getTransitionState());
|
|
||||||
}
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
final PipAnimationController.PipTransitionAnimator animator =
|
final PipAnimationController.PipTransitionAnimator animator =
|
||||||
@@ -1437,8 +1434,9 @@ public class PipTaskOrganizer implements ShellTaskOrganizer.TaskListener,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (mLeash == null || !mLeash.isValid()) {
|
if (mLeash == null || !mLeash.isValid()) {
|
||||||
Log.e(TAG, String.format("scheduleFinishResizePip with null leash! mState=%d",
|
ProtoLog.d(ShellProtoLogGroup.WM_SHELL_PICTURE_IN_PICTURE,
|
||||||
mPipTransitionState.getTransitionState()));
|
"%s: scheduleFinishResizePip with null leash! mState=%d",
|
||||||
|
TAG, mPipTransitionState.getTransitionState());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -42,7 +42,8 @@ public enum ShellProtoLogGroup implements IProtoLogGroup {
|
|||||||
"ShellBackPreview"),
|
"ShellBackPreview"),
|
||||||
WM_SHELL_RECENT_TASKS(Consts.ENABLE_DEBUG, Consts.ENABLE_LOG_TO_PROTO_DEBUG, false,
|
WM_SHELL_RECENT_TASKS(Consts.ENABLE_DEBUG, Consts.ENABLE_LOG_TO_PROTO_DEBUG, false,
|
||||||
Consts.TAG_WM_SHELL),
|
Consts.TAG_WM_SHELL),
|
||||||
WM_SHELL_PICTURE_IN_PICTURE(Consts.ENABLE_DEBUG, Consts.ENABLE_LOG_TO_PROTO_DEBUG, false,
|
// TODO(b/282232877): turn logToLogcat to false.
|
||||||
|
WM_SHELL_PICTURE_IN_PICTURE(Consts.ENABLE_DEBUG, Consts.ENABLE_LOG_TO_PROTO_DEBUG, true,
|
||||||
Consts.TAG_WM_SHELL),
|
Consts.TAG_WM_SHELL),
|
||||||
WM_SHELL_SPLIT_SCREEN(Consts.ENABLE_DEBUG, Consts.ENABLE_LOG_TO_PROTO_DEBUG, true,
|
WM_SHELL_SPLIT_SCREEN(Consts.ENABLE_DEBUG, Consts.ENABLE_LOG_TO_PROTO_DEBUG, true,
|
||||||
Consts.TAG_WM_SPLIT_SCREEN),
|
Consts.TAG_WM_SPLIT_SCREEN),
|
||||||
|
|||||||
Reference in New Issue
Block a user