Merge "Fix Keyboard stays on while startSeamlessRotation" into rvc-dev am: 641c8844ba am: 49a272a506

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12066148

Change-Id: I8d58afe762b27f730743d8f60ed3a0d0d62bb5a5
This commit is contained in:
TreeHugger Robot
2020-07-03 12:14:13 +00:00
committed by Automerger Merge Worker

View File

@@ -26,6 +26,7 @@ import static android.app.WindowConfiguration.isSplitScreenWindowingMode;
import static android.content.res.Configuration.ORIENTATION_LANDSCAPE; import static android.content.res.Configuration.ORIENTATION_LANDSCAPE;
import static android.os.PowerManager.DRAW_WAKE_LOCK; import static android.os.PowerManager.DRAW_WAKE_LOCK;
import static android.os.Trace.TRACE_TAG_WINDOW_MANAGER; import static android.os.Trace.TRACE_TAG_WINDOW_MANAGER;
import static android.view.InsetsState.ITYPE_IME;
import static android.view.SurfaceControl.Transaction; import static android.view.SurfaceControl.Transaction;
import static android.view.View.SYSTEM_UI_FLAG_HIDE_NAVIGATION; import static android.view.View.SYSTEM_UI_FLAG_HIDE_NAVIGATION;
import static android.view.View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY; import static android.view.View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY;
@@ -757,6 +758,12 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
oldRotation = mPendingSeamlessRotate.getOldRotation(); oldRotation = mPendingSeamlessRotate.getOldRotation();
} }
// Skip performing seamless rotation when the controlled insets is IME with visible state.
if (mControllableInsetProvider != null
&& mControllableInsetProvider.getSource().getType() == ITYPE_IME) {
return;
}
if (mForceSeamlesslyRotate || requested) { if (mForceSeamlesslyRotate || requested) {
if (mControllableInsetProvider != null) { if (mControllableInsetProvider != null) {
mControllableInsetProvider.startSeamlessRotation(); mControllableInsetProvider.startSeamlessRotation();