Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 07981b4f authored by Tiger Huang's avatar Tiger Huang
Browse files

Refine the condition about force layout

This CL applies SOFT_INPUT_MASK_ADJUST before comparing to
SOFT_INPUT_ADJUST_RESIZE.

Bug: 161781474
Test: atest ForceRelayoutTest ForceRelayoutSdk29Test
Change-Id: I275faafd7520df06f512c638f7c5255cc460aa02
parent 2441a6bb
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1677,7 +1677,8 @@ public final class ViewRootImpl implements ViewParent,

        // See comment for View.sForceLayoutWhenInsetsChanged
        if (View.sForceLayoutWhenInsetsChanged && mView != null
                && mWindowAttributes.softInputMode == SOFT_INPUT_ADJUST_RESIZE) {
                && (mWindowAttributes.softInputMode & SOFT_INPUT_MASK_ADJUST)
                        == SOFT_INPUT_ADJUST_RESIZE) {
            forceLayout(mView);
        }