зеркало из https://github.com/mozilla/gecko-dev.git
Bug 289910 - area invalidation not correct if new style resulted
in an empty region. r=afri, a=asa
This commit is contained in:
Родитель
0cc209fab8
Коммит
684a606a85
|
@ -362,21 +362,24 @@ nsSVGCairoGlyphGeometry::Update(PRUint32 updatemask, nsISVGRendererRegion **_ret
|
|||
nsISVGGlyphGeometrySource::UPDATEMASK_Y |
|
||||
nsISVGGeometrySource::UPDATEMASK_CANVAS_TM;
|
||||
|
||||
nsCOMPtr<nsISVGRendererRegion> before = mCoveredRegion;
|
||||
|
||||
if ((updatemask & regionsmask) || (updatemask & strokemask)) {
|
||||
nsCOMPtr<nsISVGRendererRegion> after;
|
||||
GetCoveredRegion(getter_AddRefs(after));
|
||||
|
||||
if (mCoveredRegion) {
|
||||
if (after)
|
||||
after->Combine(mCoveredRegion, _retval);
|
||||
after->Combine(before, _retval);
|
||||
} else {
|
||||
*_retval = after;
|
||||
NS_IF_ADDREF(*_retval);
|
||||
}
|
||||
mCoveredRegion = after;
|
||||
}
|
||||
else if (updatemask != nsISVGGeometrySource::UPDATEMASK_NOTHING) {
|
||||
*_retval = mCoveredRegion;
|
||||
|
||||
if (!*_retval) {
|
||||
*_retval = before;
|
||||
NS_IF_ADDREF(*_retval);
|
||||
}
|
||||
|
||||
|
|
|
@ -389,21 +389,24 @@ nsSVGCairoPathGeometry::Update(PRUint32 updatemask, nsISVGRendererRegion **_retv
|
|||
nsISVGGeometrySource::UPDATEMASK_FILL_PAINT_TYPE |
|
||||
nsISVGGeometrySource::UPDATEMASK_STROKE_PAINT_TYPE;
|
||||
|
||||
nsCOMPtr<nsISVGRendererRegion> before = mCoveredRegion;
|
||||
|
||||
if (updatemask & coveredregionmask) {
|
||||
nsCOMPtr<nsISVGRendererRegion> after;
|
||||
GetCoveredRegion(getter_AddRefs(after));
|
||||
|
||||
if (mCoveredRegion) {
|
||||
if (after)
|
||||
after->Combine(mCoveredRegion, _retval);
|
||||
after->Combine(before, _retval);
|
||||
} else {
|
||||
*_retval = after;
|
||||
NS_IF_ADDREF(*_retval);
|
||||
}
|
||||
mCoveredRegion = after;
|
||||
}
|
||||
else if (updatemask != nsISVGGeometrySource::UPDATEMASK_NOTHING) {
|
||||
*_retval = mCoveredRegion;
|
||||
|
||||
if (!*_retval) {
|
||||
*_retval = before;
|
||||
NS_IF_ADDREF(*_retval);
|
||||
}
|
||||
|
||||
|
|
|
@ -524,9 +524,10 @@ nsSVGGDIPlusGlyphGeometry::Update(PRUint32 updatemask, nsISVGRendererRegion **_r
|
|||
NS_IF_ADDREF(*_retval);
|
||||
}
|
||||
}
|
||||
else if (updatemask != nsISVGGeometrySource::UPDATEMASK_NOTHING) {
|
||||
|
||||
if (!*_retval) {
|
||||
// region hasn't changed, but something has. so invalidate whole area:
|
||||
*_retval = mCoveredRegion;
|
||||
*_retval = regionBefore;
|
||||
NS_IF_ADDREF(*_retval);
|
||||
}
|
||||
|
||||
|
|
|
@ -530,7 +530,8 @@ nsSVGGDIPlusPathGeometry::Update(PRUint32 updatemask, nsISVGRendererRegion **_re
|
|||
if (after)
|
||||
after->Combine(before, _retval);
|
||||
}
|
||||
else if (updatemask != nsISVGGeometrySource::UPDATEMASK_NOTHING) {
|
||||
|
||||
if (!*_retval) {
|
||||
*_retval = before;
|
||||
NS_IF_ADDREF(*_retval);
|
||||
}
|
||||
|
|
|
@ -395,7 +395,8 @@ nsSVGLibartPathGeometry::Update(PRUint32 updatemask, nsISVGRendererRegion **_ret
|
|||
if (after)
|
||||
after->Combine(before, _retval);
|
||||
}
|
||||
else if (updatemask != nsISVGGeometrySource::UPDATEMASK_NOTHING) {
|
||||
|
||||
if (!*_retval) {
|
||||
*_retval = before;
|
||||
NS_IF_ADDREF(*_retval);
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче