commit 4624f8e042869367eb81d763b5b16157093eb65f parent 1da10e9c11fef7044175ea6e9e3eccddb31479b1 Author: Emilio Cobos Álvarez <emilio@crisal.io> Date: Mon, 17 Nov 2025 04:39:54 +0000 Bug 2000153 - Don't check for paint listener being a view in SharedSurfacesChild. r=tnikkel That would make this work on popups. The paint suppression distinction shouldn't matter much in practice, I don't think. Differential Revision: https://phabricator.services.mozilla.com/D272736 Diffstat:
| M | gfx/layers/ipc/SharedSurfacesChild.cpp | | | 13 | +++---------- |
1 file changed, 3 insertions(+), 10 deletions(-)
diff --git a/gfx/layers/ipc/SharedSurfacesChild.cpp b/gfx/layers/ipc/SharedSurfacesChild.cpp @@ -503,16 +503,9 @@ nsresult SharedSurfacesAnimation::SetCurrentFrame( // Only root compositor bridge childs record if they are paused, so check // the refresh driver. if (auto* widget = entry.mManager->LayerManager()->GetWidget()) { - nsIWidgetListener* wl = widget->GetPaintListener(); - // Note call to wl->GetView() to make sure this is view type widget - // listener even though we don't use the view in this code. - // FIXME(emilio): Do popups do the right thing here? Maybe we should not - // check for GetView()? - if (wl && wl->GetView() && wl->GetPresShell()) { - if (auto* rd = wl->GetPresShell()->GetRefreshDriver()) { - if (rd->IsThrottled()) { - continue; - } + if (auto* ps = widget->GetPresShell()) { + if (auto* rd = ps->GetRefreshDriver(); rd && rd->IsThrottled()) { + continue; } } }