Merge "Bail early if mToken.asBinder() not found"

This commit is contained in:
Hongwei Wang
2020-09-28 18:11:33 +00:00
committed by Android (Google) Code Review

View File

@@ -325,9 +325,13 @@ public class PipTaskOrganizer extends TaskOrganizer implements ShellTaskOrganize
return;
}
final Configuration initialConfig = mInitialState.remove(mToken.asBinder());
if (initialConfig == null) {
Log.wtf(TAG, "Token not in record, this should not happen mToken=" + mToken);
return;
}
mPipUiEventLoggerLogger.log(
PipUiEventLogger.PipUiEventEnum.PICTURE_IN_PICTURE_EXPAND_TO_FULLSCREEN);
final Configuration initialConfig = mInitialState.remove(mToken.asBinder());
final boolean orientationDiffers = initialConfig.windowConfiguration.getRotation()
!= mPipBoundsHandler.getDisplayRotation();
final WindowContainerTransaction wct = new WindowContainerTransaction();