Bug 1431855: Flush notifications via the document in SVGDocumentWrapper. r=dholbert

MozReview-Commit-ID: BMmhvqFE7O7

--HG--
extra : rebase_source : 516aaaae3b9b6de9e72d2fc724b08385ae09e4e7
This commit is contained in:
Emilio Cobos Álvarez 2018-01-19 23:51:30 +01:00
parent 52ab84dbf1
commit 74425c36d7

View File

@ -419,10 +419,8 @@ SVGDocumentWrapper::UnregisterForXPCOMShutdown()
void
SVGDocumentWrapper::FlushLayout()
{
nsCOMPtr<nsIPresShell> presShell;
mViewer->GetPresShell(getter_AddRefs(presShell));
if (presShell) {
presShell->FlushPendingNotifications(FlushType::Layout);
if (nsIDocument* doc = GetDocument()) {
doc->FlushPendingNotifications(FlushType::Layout);
}
}