From 3fcb63ffc06175ae17a2032de9540a5d39c1bbba Mon Sep 17 00:00:00 2001 From: "rods%netscape.com" Date: Wed, 22 Dec 1999 19:50:47 +0000 Subject: [PATCH] changed clipping in Paint to be intersect instead of replace r=kmcclusk git-svn-id: svn://10.0.0.236/trunk@56397 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/layout/forms/nsHTMLButtonControlFrame.cpp | 4 ++-- mozilla/layout/html/forms/src/nsHTMLButtonControlFrame.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mozilla/layout/forms/nsHTMLButtonControlFrame.cpp b/mozilla/layout/forms/nsHTMLButtonControlFrame.cpp index 1291b98b90d..c09a63918d7 100644 --- a/mozilla/layout/forms/nsHTMLButtonControlFrame.cpp +++ b/mozilla/layout/forms/nsHTMLButtonControlFrame.cpp @@ -424,7 +424,7 @@ nsHTMLButtonControlFrame::Paint(nsIPresContext* aPresContext, { const nsStyleDisplay* disp = (const nsStyleDisplay*) mStyleContext->GetStyleData(eStyleStruct_Display); - if (disp->mVisible) + if (disp->mVisible == NS_STYLE_VISIBILITY_VISIBLE) { nsRect rect(0, 0, mRect.width, mRect.height); mRenderer.PaintButton(aPresContext, aRenderingContext, aDirtyRect, aWhichLayer, rect); @@ -453,7 +453,7 @@ nsHTMLButtonControlFrame::Paint(nsIPresContext* aPresContext, aRenderingContext.PushState(); PRBool clipEmpty; - aRenderingContext.SetClipRect(rect, nsClipCombine_kReplace, clipEmpty); + aRenderingContext.SetClipRect(rect, nsClipCombine_kIntersect, clipEmpty); PaintChildren(aPresContext, aRenderingContext, aDirtyRect, aWhichLayer); diff --git a/mozilla/layout/html/forms/src/nsHTMLButtonControlFrame.cpp b/mozilla/layout/html/forms/src/nsHTMLButtonControlFrame.cpp index 1291b98b90d..c09a63918d7 100644 --- a/mozilla/layout/html/forms/src/nsHTMLButtonControlFrame.cpp +++ b/mozilla/layout/html/forms/src/nsHTMLButtonControlFrame.cpp @@ -424,7 +424,7 @@ nsHTMLButtonControlFrame::Paint(nsIPresContext* aPresContext, { const nsStyleDisplay* disp = (const nsStyleDisplay*) mStyleContext->GetStyleData(eStyleStruct_Display); - if (disp->mVisible) + if (disp->mVisible == NS_STYLE_VISIBILITY_VISIBLE) { nsRect rect(0, 0, mRect.width, mRect.height); mRenderer.PaintButton(aPresContext, aRenderingContext, aDirtyRect, aWhichLayer, rect); @@ -453,7 +453,7 @@ nsHTMLButtonControlFrame::Paint(nsIPresContext* aPresContext, aRenderingContext.PushState(); PRBool clipEmpty; - aRenderingContext.SetClipRect(rect, nsClipCombine_kReplace, clipEmpty); + aRenderingContext.SetClipRect(rect, nsClipCombine_kIntersect, clipEmpty); PaintChildren(aPresContext, aRenderingContext, aDirtyRect, aWhichLayer);