Skip moving PiP for IME/shelf change if user is dragging.
Tapping on the PiP will already make isUserInteracting equal to true. However, user might have simply tapped it to open the menu. Defer the movement only if user is actively dragging PiP (aka changing the position of PiP while using another touch point to e.g. open IME). This also will make PiP move above IME anyways, when user finishes the drag. Bug: 255689034 Test: open PiP, tap it to show PiP menu, open IME, pip moves away Test: open PiP, while dragging open IME with another finger, pip stays Change-Id: If5830ed783cf969d4eba8a91f235e008a6e13680
This commit is contained in:
@@ -427,7 +427,7 @@ public class PipTouchHandler {
|
||||
// If this is from an IME or shelf adjustment, then we should move the PiP so that it is not
|
||||
// occluded by the IME or shelf.
|
||||
if (fromImeAdjustment || fromShelfAdjustment) {
|
||||
if (mTouchState.isUserInteracting()) {
|
||||
if (mTouchState.isUserInteracting() && mTouchState.isDragging()) {
|
||||
// Defer the update of the current movement bounds until after the user finishes
|
||||
// touching the screen
|
||||
} else if (ENABLE_PIP_KEEP_CLEAR_ALGORITHM) {
|
||||
|
||||
Reference in New Issue
Block a user