mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-08 19:04:45 +00:00
Bug 907503 - Fix invalidation for SMIL animation in SVG-as-an-image. r=roc
This commit is contained in:
parent
774ee65e35
commit
7e60ad4ae6
@ -1141,7 +1141,16 @@ void nsDisplayList::PaintForFrame(nsDisplayListBuilder* aBuilder,
|
|||||||
BuildContainerLayerFor(aBuilder, layerManager, aForFrame, nullptr, *this,
|
BuildContainerLayerFor(aBuilder, layerManager, aForFrame, nullptr, *this,
|
||||||
containerParameters, nullptr);
|
containerParameters, nullptr);
|
||||||
|
|
||||||
if (widgetTransaction) {
|
nsIDocument* document = nullptr;
|
||||||
|
if (presShell) {
|
||||||
|
document = presShell->GetDocument();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (widgetTransaction ||
|
||||||
|
// SVG-as-an-image docs don't paint as part of the retained layer tree,
|
||||||
|
// but they still need the invalidation state bits cleared in order for
|
||||||
|
// invalidation for CSS/SMIL animation to work properly.
|
||||||
|
(document && document->IsBeingUsedAsImage())) {
|
||||||
aForFrame->ClearInvalidationStateBits();
|
aForFrame->ClearInvalidationStateBits();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1177,13 +1186,10 @@ void nsDisplayList::PaintForFrame(nsDisplayListBuilder* aBuilder,
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool mayHaveTouchListeners = false;
|
bool mayHaveTouchListeners = false;
|
||||||
if (presShell) {
|
if (document) {
|
||||||
nsIDocument* document = presShell->GetDocument();
|
nsCOMPtr<nsPIDOMWindow> innerWin(document->GetInnerWindow());
|
||||||
if (document) {
|
if (innerWin) {
|
||||||
nsCOMPtr<nsPIDOMWindow> innerWin(document->GetInnerWindow());
|
mayHaveTouchListeners = innerWin->HasTouchEventListeners();
|
||||||
if (innerWin) {
|
|
||||||
mayHaveTouchListeners = innerWin->HasTouchEventListeners();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user