For #18122 - Update browser layout for find in page bar with bottom toolbar

With a dynamic bottom toolbar the  browser extends all the way to the bottom of
the screen and so when the find in page bar is shown it will be so above the
bottom part of the browser which may contain exactly the searched for items.

To fix the browser must effectively be placed at the top of the newly shown
find in page bar.
upstream-sync
Mugurell 3 years ago committed by Mihai Adrian Carare
parent b36431a6df
commit 660f0609cb

@ -67,6 +67,10 @@ class FindInPageIntegration(
} else {
engineViewParent.translationY = 0f
}
} else {
if (toolbarInfo.isToolbarDynamic) {
engineViewParentParams.bottomMargin = 0
}
}
}
@ -86,6 +90,10 @@ class FindInPageIntegration(
// With a fixed toolbar the EngineView is anchored below the toolbar with 0 Y translation.
engineViewParent.translationY = -toolbarInfo.toolbar.height.toFloat()
}
} else {
// With a bottom toolbar the EngineView is already anchored to the top of the screen.
// Need just to ensure space for the find in page bar under the engineView.
engineViewParentParams.bottomMargin = toolbarInfo.toolbar.height
}
}

Loading…
Cancel
Save