Fix bug 387154 -- rendering of narrow buttons (for which we need to scoot the

text over to the left) regressed.  r+sr=dbaron


git-svn-id: svn://10.0.0.236/trunk@229460 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bzbarsky%mit.edu
2007-07-07 00:48:29 +00:00
parent d6b9491228
commit 5b50f03234
4 changed files with 72 additions and 2 deletions

View File

@@ -347,7 +347,6 @@ nsHTMLButtonControlFrame::ReflowButtonContents(nsPresContext* aPresContext,
// Indent the child inside us by the focus border. We must do this separate
// from the regular border.
availSize.width -= aFocusPadding.LeftRight();
availSize.width = PR_MAX(availSize.width,0);
// See whether out availSize's width is big enough. If it's smaller than our
// intrinsic min width, that means that the kid wouldn't really fit; for a
@@ -367,6 +366,7 @@ nsHTMLButtonControlFrame::ReflowButtonContents(nsPresContext* aPresContext,
xoffset -= extraleft;
availSize.width += extraleft + extraright;
}
availSize.width = PR_MAX(availSize.width,0);
nsHTMLReflowState reflowState(aPresContext, aReflowState, aFirstKid,
availSize);