Bug 1604956 - Avoid calling HasPaintedDisplayPort() with a null content element. r=tnikkel

Differential Revision: https://phabricator.services.mozilla.com/D57719

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Botond Ballo 2019-12-19 00:12:29 +00:00
Родитель 42eb841eff
Коммит be4d75b35a
1 изменённых файлов: 4 добавлений и 1 удалений

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

@ -715,7 +715,10 @@ static bool PrepareForSetTargetAPZCNotification(
&(guid.mScrollableLayerGuid.mScrollId));
aTargets->AppendElement(guid);
if (!guidIsValid || nsLayoutUtils::HasDisplayPort(dpElement)) {
if (!guidIsValid) {
return false;
}
if (nsLayoutUtils::HasDisplayPort(dpElement)) {
// If the element has a displayport but it hasn't been painted yet,
// we want the caller to wait for the paint to happen, but we don't
// need to set the displayport here since it's already been set.