b=448193, 3d border effects missing with moz-border-radius; r=zweinberg
authorVladimir Vukicevic <vladimir@pobox.com>
Thu, 09 Oct 2008 14:49:15 -0700
changeset 20225 60a855404ff85f9f4fdcedafa07b9b0b339b452b
parent 20224 ab96d199ce9b55292835e2afc17d717d8dc6f022
child 20226 63c6632d85986a434ddf977b2545fd90b769aa29
push idunknown
push userunknown
push dateunknown
reviewerszweinberg
bugs448193
milestone1.9.1b2pre
b=448193, 3d border effects missing with moz-border-radius; r=zweinberg
layout/base/nsCSSRenderingBorders.cpp
layout/reftests/bugs/reftest.list
--- a/layout/base/nsCSSRenderingBorders.cpp
+++ b/layout/base/nsCSSRenderingBorders.cpp
@@ -1183,18 +1183,25 @@ nsCSSBorderRenderer::DrawBorders()
       mContext->Restore();
 
       SN();
     }
 
     // in the case of a single-unit border, we already munged the
     // corners up above; so we can just draw the top left and bottom
     // right sides separately, if they're the same.
+    //
+    // We need to check for mNoBorderRadius, because when there is
+    // one, FillSolidBorder always draws the full rounded rectangle
+    // and expects there to be a clip in place.
     PRIntn alreadyDrawnSides = 0;
-    if (mOneUnitBorder && (dashedSides & (SIDE_BIT_TOP | SIDE_BIT_LEFT)) == 0) {
+    if (mOneUnitBorder &&
+        mNoBorderRadius &&
+        (dashedSides & (SIDE_BIT_TOP | SIDE_BIT_LEFT)) == 0)
+    {
       if (tlBordersSame) {
         DrawBorderSides(SIDE_BIT_TOP | SIDE_BIT_LEFT);
         alreadyDrawnSides |= (SIDE_BIT_TOP | SIDE_BIT_LEFT);
       }
 
       if (brBordersSame && (dashedSides & (SIDE_BIT_BOTTOM | SIDE_BIT_RIGHT)) == 0) {
         DrawBorderSides(SIDE_BIT_BOTTOM | SIDE_BIT_RIGHT);
         alreadyDrawnSides |= (SIDE_BIT_BOTTOM | SIDE_BIT_RIGHT);
--- a/layout/reftests/bugs/reftest.list
+++ b/layout/reftests/bugs/reftest.list
@@ -906,16 +906,17 @@ random == 429849-1.html 429849-1-ref.htm
 == 439639-1.html 439639-1-ref.html
 == 439910.html 439910-ref.html
 == 441259-1.html 441259-1-ref.html
 fails == 441259-2.html 441259-2-ref.html # bug 441400
 == 444015-1.html 444015-1-ref.html
 == 444928-1.html 444928-1-ref.html
 == 444928-2.html 444928-2-ref.html
 != 444928-3.html 444928-3-notref.html
+# == 448193.html 448193-ref.html  # Fails due to 2 small single-pixel differences
 # == 448987.html 448987-ref.html  # Disabled for now - it needs privileges
 == 449171-1.html 449171-ref.html
 == 449519-1.html 449519-1-ref.html
 # == 449653-1.html 449653-1-ref.html # Disabled for now - it needs privileges
 == 450670-1.html 450670-1-ref.html
 == 451168-1.html 451168-1-ref.html
 == 452964-1.html 452964-1-ref.html
 == 454361.html about:blank