OSDN Git Service

Do not set the divider pos during adjust ime and minimized interaction
authorMatthew Ng <ngmatthew@google.com>
Tue, 23 May 2017 20:00:24 +0000 (13:00 -0700)
committerMatthew Ng <ngmatthew@google.com>
Tue, 30 May 2017 18:42:41 +0000 (11:42 -0700)
When launching an app in splitscreen with while ime is up will trigger
an animation that is trying to minimize the docked stack (this bug is
tracked in b/36603383) with the end result in incorrect bounds for the
docked and fullscreen tasks (leaving visual glitches in their apps).
This was caused by setting the divider position while there was
interaction with the minimized state. Therefore ignore setting divider
while adjusting for ime and minimized interaction for the tasks to end
with the correct bounds.

Fixes: 38428386
Test: manual - dock something in split screen, use the launcher search
to bring up ime, launch any app (like gmail)
Change-Id: Ic3547b02a39f40698db07d1c0946e0991b69f5d3

packages/SystemUI/src/com/android/systemui/stackdivider/DividerView.java

index 0c77036..ecfa4ff 100644 (file)
@@ -825,7 +825,10 @@ public class DividerView extends FrameLayout implements OnTouchListener,
                 .setDuration(animDuration)
                 .start();
         mAdjustedForIme = adjustedForIme;
-        if (mHomeStackResizable && adjustedForIme) {
+
+        // Only get new position if home stack is resizable, ime is open and not minimized
+        // (including the animation)
+        if (mHomeStackResizable && adjustedForIme && !mIsInMinimizeInteraction) {
             mDividerPositionBeforeMinimized = getCurrentPosition();
         }
     }