зеркало из https://github.com/mozilla/pjs.git
backout 0f4a08fb2e8e to see if it caused random orange (Bug 756122 - Clean up nsSVGUtils::PaintFrameWithEffects a little).
This commit is contained in:
Родитель
74cacb12c6
Коммит
04369e993a
|
@ -1166,6 +1166,15 @@ nsSVGUtils::PaintFrameWithEffects(nsRenderingContext *aContext,
|
|||
return;
|
||||
}
|
||||
|
||||
/* Properties are added lazily and may have been removed by a restyle,
|
||||
so make sure all applicable ones are set again. */
|
||||
|
||||
nsSVGEffects::EffectProperties effectProperties =
|
||||
nsSVGEffects::GetEffectProperties(aFrame);
|
||||
|
||||
bool isOK = true;
|
||||
nsSVGFilterFrame *filterFrame = effectProperties.GetFilterFrame(&isOK);
|
||||
|
||||
if (aDirtyRect &&
|
||||
!(aFrame->GetStateBits() & NS_STATE_SVG_NONDISPLAY_CHILD)) {
|
||||
// Here we convert aFrame's paint bounds to outer-<svg> device space,
|
||||
|
@ -1218,24 +1227,16 @@ nsSVGUtils::PaintFrameWithEffects(nsRenderingContext *aContext,
|
|||
gfxContext *gfx = aContext->ThebesContext();
|
||||
bool complexEffects = false;
|
||||
|
||||
/* Properties are added lazily and may have been removed by a restyle,
|
||||
so make sure all applicable ones are set again. */
|
||||
|
||||
nsSVGEffects::EffectProperties effectProperties =
|
||||
nsSVGEffects::GetEffectProperties(aFrame);
|
||||
|
||||
bool isOK = true;
|
||||
nsSVGFilterFrame *filterFrame = effectProperties.GetFilterFrame(&isOK);
|
||||
nsSVGClipPathFrame *clipPathFrame = effectProperties.GetClipPathFrame(&isOK);
|
||||
nsSVGMaskFrame *maskFrame = effectProperties.GetMaskFrame(&isOK);
|
||||
|
||||
bool isTrivialClip = clipPathFrame ? clipPathFrame->IsTrivial() : true;
|
||||
|
||||
if (!isOK) {
|
||||
// Some resource is invalid. We shouldn't paint anything.
|
||||
return;
|
||||
}
|
||||
|
||||
bool isTrivialClip = clipPathFrame ? clipPathFrame->IsTrivial() : true;
|
||||
|
||||
gfxMatrix matrix;
|
||||
if (clipPathFrame || maskFrame)
|
||||
matrix = GetCanvasTM(aFrame);
|
||||
|
|
Загрузка…
Ссылка в новой задаче