Keep ime information up-to-date even when divider invisible
Otherwise, it can accidentally put the divider into ime
mode when there isn't an ime.
Bug: 159380790
Test: with minimized primary, open ime in launcher then expand
primary to leave split mode. Re-enter min primary and
rotate device. Open an app in secondary and make sure
it doesn't dim the primary.
Change-Id: I68a9b56073b247e0a63c6670a9e1b330014bebc8
This commit is contained in:
@@ -126,16 +126,16 @@ class DividerImeController implements DisplayImeController.ImePositionProcessor
|
||||
@Override
|
||||
public void onImeStartPositioning(int displayId, int hiddenTop, int shownTop,
|
||||
boolean imeShouldShow, SurfaceControl.Transaction t) {
|
||||
mHiddenTop = hiddenTop;
|
||||
mShownTop = shownTop;
|
||||
mTargetShown = imeShouldShow;
|
||||
if (!isDividerVisible()) {
|
||||
return;
|
||||
}
|
||||
final boolean splitIsVisible = !getView().isHidden();
|
||||
mSecondaryHasFocus = getSecondaryHasFocus(displayId);
|
||||
final boolean targetAdjusted = splitIsVisible && imeShouldShow && mSecondaryHasFocus
|
||||
&& !getLayout().mDisplayLayout.isLandscape();
|
||||
mHiddenTop = hiddenTop;
|
||||
mShownTop = shownTop;
|
||||
mTargetShown = imeShouldShow;
|
||||
&& !getLayout().mDisplayLayout.isLandscape() && !mSplits.mDivider.isMinimized();
|
||||
if (mLastAdjustTop < 0) {
|
||||
mLastAdjustTop = imeShouldShow ? hiddenTop : shownTop;
|
||||
} else if (mLastAdjustTop != (imeShouldShow ? mShownTop : mHiddenTop)) {
|
||||
|
||||
Reference in New Issue
Block a user