From dbaee656fc96afe48c9bfa1eaca4ebdf27f57e48 Mon Sep 17 00:00:00 2001 From: "rods@netscape.com" Date: Sat, 4 Sep 1999 13:34:40 +0000 Subject: [PATCH] Fills in background color webshell gets centered and the size is large then the minium --- layout/html/forms/src/nsGfxTextControlFrame.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/layout/html/forms/src/nsGfxTextControlFrame.cpp b/layout/html/forms/src/nsGfxTextControlFrame.cpp index 9054f7bd3382..a54194a4e1c8 100644 --- a/layout/html/forms/src/nsGfxTextControlFrame.cpp +++ b/layout/html/forms/src/nsGfxTextControlFrame.cpp @@ -612,6 +612,9 @@ nsGfxTextControlFrame::PaintTextControl(nsIPresContext& aPresContext, aStyleContext, skipSides, nsnull, borderTwips, PR_TRUE); } else { + const nsStyleColor* color = (const nsStyleColor*)mStyleContext->GetStyleData(eStyleStruct_Color); + nsCSSRendering::PaintBackground(aPresContext, aRenderingContext, this, + aDirtyRect, rect, *color, *mySpacing, 0, 0); //PaintTextControl(aPresContext, aRenderingContext, text, mStyleContext, rect); nsCSSRendering::PaintBorder(aPresContext, aRenderingContext, this, aDirtyRect, rect, *mySpacing, aStyleContext, skipSides); @@ -957,7 +960,7 @@ nsGfxTextControlFrame::Reflow(nsIPresContext& aPresContext, // Get the CSS border const nsStyleSpacing* spacing; GetStyleData(eStyleStruct_Spacing, (const nsStyleStruct *&)spacing); - spacing->CalcBorderFor(this, border); + spacing->CalcBorderPaddingFor(this, border); } float t2p;