const nsSize& aMaxSize,
nsInputTextFrame::GetDesiredSize(nsIPresContext* aPresContext,                                 const nsReflowState& aReflowState,                                 const nsSize& aMaxSize,                                 nsReflowMetrics& aDesiredLayoutSize,                                 nsSize& aDesiredWidgetSize){  nsInputTextType textType = GetTextType();  // get the css size and let the frame use or override it  nsSize styleSize;  GetStyleSize(*aPresContext, aReflowState, styleSize);  nsSize size;    PRBool widthExplicit, heightExplicit;  PRInt32 ignore;  if ((kInputText_Text == textType) || (kInputText_Password == textType) ||      (kInputText_FileText == textType))   {    nsInputDimensionSpec textSpec(nsHTMLAtoms::size, PR_FALSE, nsHTMLAtoms::value,                                  20, PR_FALSE, nsnull, 1);    CalculateSize(aPresContext, this, styleSize, textSpec, size,                   widthExplicit, heightExplicit, ignore);  }   else {    nsInputDimensionSpec areaSpec(nsHTMLAtoms::cols, PR_FALSE, nsnull, 10,                                   PR_FALSE, nsHTMLAtoms::rows, 1);    CalculateSize(aPresContext, this, styleSize, areaSpec, size,                   widthExplicit, heightExplicit, ignore);  }  if (!heightExplicit) {    if (kInputText_Area == textType) {      size.height += gScrollBarWidth;    }     else {      size.height += 100;    }  }  if (!widthExplicit && (kInputText_Area == textType)) {    size.width += gScrollBarWidth;  }  aDesiredLayoutSize.width  = size.width;  aDesiredLayoutSize.height = size.height;  aDesiredLayoutSize.ascent = aDesiredLayoutSize.height;  aDesiredLayoutSize.descent = 0;  aDesiredWidgetSize.width  = aDesiredLayoutSize.width;  aDesiredWidgetSize.height = aDesiredLayoutSize.height;}