b=379328, focus outline rendering regression fix

git-svn-id: svn://10.0.0.236/trunk@225324 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
vladimir%pobox.com
2007-05-01 04:58:44 +00:00
parent 92ccf06bb6
commit fe4c4a3356

View File

@@ -2356,18 +2356,19 @@ nsCSSRendering::PaintOutline(nsPresContext* aPresContext,
oRect.size.width - (2*width) / (2.0 * twipsPerPixel),
oRect.size.height - (2*width) / (2.0 * twipsPerPixel));
// default to current color in case it is invert color
// and the platform does not support that
nscolor outlineColor(ourColor->mColor);
nscolor outlineColor;
// PR_FALSE means use the initial color; PR_TRUE means a color was
// set.
if (!aOutlineStyle.GetOutlineColor(outlineColor))
outlineColor = ourColor->mColor;
PRUint8 outlineStyle = aOutlineStyle.GetOutlineStyle();
// grab the thebes context
nsRefPtr<gfxContext> ctx = (gfxContext*)
aRenderingContext.GetNativeGraphicData(nsIRenderingContext::NATIVE_THEBES_CONTEXT);
PRUint8 outlineStyle = aOutlineStyle.GetOutlineStyle();
if (!aOutlineStyle.GetOutlineColor(outlineColor))
return;
ctx->Save();
// Clamp the CTM to be pixel-aligned; we do this only