Align text inputs, buttons, comboboxes to baseline with respect to the

text around them (bug 167236).  Fix width sizing issues for <input
type="button/reset/submit"> (bugs 79927, 36364).  Fix nonuniform heights
of form controls (bug 70251).  Patch is on bug 167236, r=jkeiser,
sr=roc+moz, moa=rods


git-svn-id: svn://10.0.0.236/trunk@133674 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bzbarsky%mit.edu
2002-11-12 19:17:51 +00:00
parent 5e08a3cbc0
commit 87e0051c3e
21 changed files with 187 additions and 582 deletions

View File

@@ -837,7 +837,8 @@ nsListControlFrame::Reflow(nsIPresContext* aPresContext,
// so we can check timings against the old version
#if 1
nsFormControlFrame::SkipResizeReflow(mCacheSize,
nsFormControlFrame::SkipResizeReflow(mCacheSize,
mCachedAscent,
mCachedMaxElementSize,
mCachedAvailableSize,
aDesiredSize, aReflowState,
@@ -999,6 +1000,7 @@ nsListControlFrame::Reflow(nsIPresContext* aPresContext,
}
mCachedUnconstrainedSize.width = scrolledAreaDesiredSize.width;
mCachedUnconstrainedSize.height = scrolledAreaDesiredSize.height;
mCachedAscent = scrolledAreaDesiredSize.ascent;
mCachedDesiredMaxSize.width = scrolledAreaDesiredSize.maxElementSize->width;
mCachedDesiredMaxSize.height = scrolledAreaDesiredSize.maxElementSize->height;
} else {
@@ -1280,8 +1282,9 @@ nsListControlFrame::Reflow(nsIPresContext* aPresContext,
} else {
aDesiredSize.width = visibleWidth;
aDesiredSize.height = visibleHeight;
aDesiredSize.ascent = aDesiredSize.height;
aDesiredSize.descent = 0;
aDesiredSize.ascent =
scrolledAreaDesiredSize.ascent + aReflowState.mComputedBorderPadding.top;
aDesiredSize.descent = aDesiredSize.height - aDesiredSize.ascent;
}
if (nsnull != aDesiredSize.maxElementSize) {
@@ -1319,7 +1322,8 @@ nsListControlFrame::Reflow(nsIPresContext* aPresContext,
//REFLOW_DEBUG_MSG3("** nsLCF Caching AW: %d AH: %d\n", PX(mCachedAvailableSize.width), PX(mCachedAvailableSize.height));
nsFormControlFrame::SetupCachedSizes(mCacheSize, mCachedMaxElementSize, aDesiredSize);
nsFormControlFrame::SetupCachedSizes(mCacheSize, mCachedAscent,
mCachedMaxElementSize, aDesiredSize);
REFLOW_DEBUG_MSG3("** Done nsLCF DW: %d DH: %d\n\n", PX(aDesiredSize.width), PX(aDesiredSize.height));