Backout Bug 649114 - Reftest failures

This commit is contained in:
Robert Longson 2012-01-23 20:40:09 +00:00
Родитель 7464c0e48f
Коммит 55706c3392
4 изменённых файлов: 18 добавлений и 23 удалений

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

@ -100,7 +100,6 @@ random-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) == dynamic-text-04.svg dyna
== dynamic-text-05.svg pass.svg
== dynamic-text-06.svg pass.svg
== dynamic-text-07.svg dynamic-text-07-ref.svg
== dynamic-text-08.svg dynamic-text-08-ref.svg
== dynamic-textPath-01.svg dynamic-textPath-01-ref.svg
== dynamic-use-01.svg pass.svg
== dynamic-use-02.svg pass.svg

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

@ -138,10 +138,16 @@ nsSVGAFrame::AttributeChanged(PRInt32 aNameSpaceID,
nsIAtom* aAttribute,
PRInt32 aModType)
{
if (aNameSpaceID == kNameSpaceID_None &&
aAttribute == nsGkAtoms::transform) {
if (aNameSpaceID != kNameSpaceID_None)
return NS_OK;
NotifySVGChanged(TRANSFORM_CHANGED);
if (aAttribute == nsGkAtoms::transform) {
// transform has changed
// make sure our cached transform matrix gets (lazily) updated
mCanvasTM = nsnull;
nsSVGUtils::NotifyChildrenOfSVGChange(this, TRANSFORM_CHANGED);
}
return NS_OK;

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

@ -111,8 +111,10 @@ nsSVGGFrame::AttributeChanged(PRInt32 aNameSpaceID,
{
if (aNameSpaceID == kNameSpaceID_None &&
aAttribute == nsGkAtoms::transform) {
// make sure our cached transform matrix gets (lazily) updated
mCanvasTM = nsnull;
NotifySVGChanged(TRANSFORM_CHANGED);
nsSVGUtils::NotifyChildrenOfSVGChange(this, TRANSFORM_CHANGED);
}
return NS_OK;

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

@ -89,8 +89,12 @@ nsSVGTextFrame::AttributeChanged(PRInt32 aNameSpaceID,
return NS_OK;
if (aAttribute == nsGkAtoms::transform) {
// transform has changed
NotifySVGChanged(TRANSFORM_CHANGED);
// make sure our cached transform matrix gets (lazily) updated
mCanvasTM = nsnull;
nsSVGUtils::NotifyChildrenOfSVGChange(this, TRANSFORM_CHANGED);
} else if (aAttribute == nsGkAtoms::x ||
aAttribute == nsGkAtoms::y ||
@ -181,30 +185,14 @@ nsSVGTextFrame::GetRotationOfChar(PRUint32 charnum, float *_retval)
void
nsSVGTextFrame::NotifySVGChanged(PRUint32 aFlags)
{
bool updateGlyphMetrics = false;
if (aFlags & COORD_CONTEXT_CHANGED) {
updateGlyphMetrics = true;
}
if (aFlags & TRANSFORM_CHANGED) {
if (mCanvasTM && mCanvasTM->IsSingular()) {
// We won't have calculated the glyph positions correctly
updateGlyphMetrics = true;
}
// make sure our cached transform matrix gets (lazily) updated
mCanvasTM = nsnull;
}
if (updateGlyphMetrics) {
// NotifyGlyphMetricsChange will invalidate all children.
// No need for them to invalidate themselves
aFlags |= SUPPRESS_INVALIDATION;
}
nsSVGTextFrameBase::NotifySVGChanged(aFlags);
if (updateGlyphMetrics) {
if (aFlags & COORD_CONTEXT_CHANGED) {
// If we are positioned using percentage values we need to update our
// position whenever our viewport's dimensions change.