mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-03-01 05:48:26 +00:00

If the visual viewport offset is not set on the presshell then calling GetVisualViewportOffset returns (0, 0). This then causes us to introduce an incorrect offset between the layout scroll offset and the visual viewport offset that didn't exist before. Logically we want to treat an unset visual viewport offset as the layout scroll offset. Other possible fixes: -make PresShell::GetVisualViewportOffset return the layout scroll offset if a visual viewport offset is not set -make this if conditional on a visual viewport offset already being set -the combination of the two above All of these fail some tests on try server. I haven't investigated why. If we want to go with any of those potential fixes in the future then this patch is a step on the way there Differential Revision: https://phabricator.services.mozilla.com/D137873