Merge "Fix the expand button changing too soon"
This commit is contained in:
@@ -200,7 +200,7 @@ public class TvPipMenuController implements PipMenuController, TvPipMenuView.Lis
|
||||
void notifyPipAnimating(boolean animating) {
|
||||
mPipMenuView.setEduTextActive(!animating);
|
||||
if (!animating) {
|
||||
mPipMenuView.onPipTransitionFinished();
|
||||
mPipMenuView.onPipTransitionFinished(mTvPipBoundsState.isTvPipExpanded());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -267,7 +267,6 @@ public class TvPipMenuController implements PipMenuController, TvPipMenuView.Lis
|
||||
void updateExpansionState() {
|
||||
mPipMenuView.setExpandedModeEnabled(mTvPipBoundsState.isTvExpandedPipSupported()
|
||||
&& mTvPipBoundsState.getDesiredTvExpandedAspectRatio() != 0);
|
||||
mPipMenuView.setIsExpanded(mTvPipBoundsState.isTvPipExpanded());
|
||||
}
|
||||
|
||||
private Rect calculateMenuSurfaceBounds(Rect pipBounds) {
|
||||
|
||||
@@ -266,7 +266,7 @@ public class TvPipMenuView extends FrameLayout implements View.OnClickListener {
|
||||
}
|
||||
}
|
||||
|
||||
void onPipTransitionFinished() {
|
||||
void onPipTransitionFinished(boolean isTvPipExpanded) {
|
||||
ProtoLog.d(ShellProtoLogGroup.WM_SHELL_PICTURE_IN_PICTURE,
|
||||
"%s: onPipTransitionFinished()", TAG);
|
||||
|
||||
@@ -277,6 +277,8 @@ public class TvPipMenuView extends FrameLayout implements View.OnClickListener {
|
||||
.setInterpolator(TvPipInterpolators.ENTER)
|
||||
.start();
|
||||
|
||||
setIsExpanded(isTvPipExpanded);
|
||||
|
||||
// Update buttons.
|
||||
if (mSwitchingOrientation) {
|
||||
mActionButtonsContainer.animate()
|
||||
|
||||
Reference in New Issue
Block a user