Merge "PiP: Re-attach PiP menu when display changes." into tm-dev
This commit is contained in:
@@ -172,7 +172,7 @@ public class PhonePipMenuController implements PipMenuController {
|
|||||||
detachPipMenuView();
|
detachPipMenuView();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void attachPipMenuView() {
|
void attachPipMenuView() {
|
||||||
// In case detach was not called (e.g. PIP unexpectedly closed)
|
// In case detach was not called (e.g. PIP unexpectedly closed)
|
||||||
if (mPipMenuView != null) {
|
if (mPipMenuView != null) {
|
||||||
detachPipMenuView();
|
detachPipMenuView();
|
||||||
|
|||||||
@@ -521,6 +521,7 @@ public class PipController implements PipTransitionController.PipTransitionCallb
|
|||||||
};
|
};
|
||||||
|
|
||||||
if (mPipTaskOrganizer.isInPip() && saveRestoreSnapFraction) {
|
if (mPipTaskOrganizer.isInPip() && saveRestoreSnapFraction) {
|
||||||
|
mMenuController.attachPipMenuView();
|
||||||
// Calculate the snap fraction of the current stack along the old movement bounds
|
// Calculate the snap fraction of the current stack along the old movement bounds
|
||||||
final PipSnapAlgorithm pipSnapAlgorithm = mPipBoundsAlgorithm.getSnapAlgorithm();
|
final PipSnapAlgorithm pipSnapAlgorithm = mPipBoundsAlgorithm.getSnapAlgorithm();
|
||||||
final Rect postChangeStackBounds = new Rect(mPipBoundsState.getBounds());
|
final Rect postChangeStackBounds = new Rect(mPipBoundsState.getBounds());
|
||||||
|
|||||||
Reference in New Issue
Block a user