Bug 1674104 - Reset the vertical clipping value to zero whenever we change the dynamic toolbar max height. r=botond

So that we will not mis-align position:fixed elements with the old stale
clipping value.

Differential Revision: https://phabricator.services.mozilla.com/D100862
This commit is contained in:
Hiroyuki Ikezoe 2021-01-06 18:05:52 +00:00
Родитель 31c970eb51
Коммит 510659d878
1 изменённых файлов: 8 добавлений и 0 удалений

Просмотреть файл

@ -171,6 +171,14 @@ public class GeckoView extends FrameLayout {
public void setDynamicToolbarMaxHeight(final int height) {
mDynamicToolbarMaxHeight = height;
// Reset the vertical clipping value to zero whenever we change
// the dynamic toolbar __max__ height so that it can be properly
// propagated to both the main thread and the compositor thread,
// thus we will be able to reset the __current__ toolbar height
// on the both threads whatever the __current__ toolbar height is.
setVerticalClipping(0);
if (mDisplay != null) {
mDisplay.setDynamicToolbarMaxHeight(height);
}