From 46de74faf001e908d81e402ff866cb413477f9ea Mon Sep 17 00:00:00 2001 From: "bzbarsky%mit.edu" Date: Tue, 21 Oct 2003 16:27:48 +0000 Subject: [PATCH] Make sure to include the border and padding in the frame size even in the "0 width" case. Bug 222990, r+sr=roc --- layout/forms/nsComboboxControlFrame.cpp | 2 +- layout/html/forms/src/nsComboboxControlFrame.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/layout/forms/nsComboboxControlFrame.cpp b/layout/forms/nsComboboxControlFrame.cpp index 1b660e2d9e7c..ae574f17a820 100644 --- a/layout/forms/nsComboboxControlFrame.cpp +++ b/layout/forms/nsComboboxControlFrame.cpp @@ -946,7 +946,7 @@ nsComboboxControlFrame::ReflowCombobox(nsIPresContext * aPresContext, aDropDownBtn->SetRect(buttonRect); SetChildFrameSize(aDropDownBtn, aBtnWidth, aDesiredSize.height); aDesiredSize.width = 0; - aDesiredSize.height = dispHeight; + aDesiredSize.height = dispHeight + aBorderPadding.top + aBorderPadding.bottom;; // XXX What about ascent and descent? return; } diff --git a/layout/html/forms/src/nsComboboxControlFrame.cpp b/layout/html/forms/src/nsComboboxControlFrame.cpp index 1b660e2d9e7c..ae574f17a820 100644 --- a/layout/html/forms/src/nsComboboxControlFrame.cpp +++ b/layout/html/forms/src/nsComboboxControlFrame.cpp @@ -946,7 +946,7 @@ nsComboboxControlFrame::ReflowCombobox(nsIPresContext * aPresContext, aDropDownBtn->SetRect(buttonRect); SetChildFrameSize(aDropDownBtn, aBtnWidth, aDesiredSize.height); aDesiredSize.width = 0; - aDesiredSize.height = dispHeight; + aDesiredSize.height = dispHeight + aBorderPadding.top + aBorderPadding.bottom;; // XXX What about ascent and descent? return; }