Bug 349259 patch 1: Add an nsIContent* parameter to nsHTMLReflowState::CalcLineHeight. r=bz

This commit is contained in:
L. David Baron
2014-03-12 20:33:21 -07:00
parent 4080144ca5
commit 68a6d16355
7 changed files with 18 additions and 14 deletions

View File

@@ -159,8 +159,8 @@ nsTextControlFrame::CalcIntrinsicSize(nsRenderingContext* aRenderingContext,
aRenderingContext->SetFont(fontMet);
lineHeight =
nsHTMLReflowState::CalcLineHeight(StyleContext(), NS_AUTOHEIGHT,
aFontSizeInflation);
nsHTMLReflowState::CalcLineHeight(GetContent(), StyleContext(),
NS_AUTOHEIGHT, aFontSizeInflation);
charWidth = fontMet->AveCharWidth();
charMaxAdvance = fontMet->MaxAdvance();
@@ -486,8 +486,8 @@ nsTextControlFrame::Reflow(nsPresContext* aPresContext,
nscoord lineHeight = aReflowState.ComputedHeight();
float inflation = nsLayoutUtils::FontSizeInflationFor(this);
if (!IsSingleLineTextControl()) {
lineHeight = nsHTMLReflowState::CalcLineHeight(StyleContext(),
NS_AUTOHEIGHT, inflation);
lineHeight = nsHTMLReflowState::CalcLineHeight(GetContent(), StyleContext(),
NS_AUTOHEIGHT, inflation);
}
nsRefPtr<nsFontMetrics> fontMet;
nsresult rv = nsLayoutUtils::GetFontMetricsForFrame(this,