Start out with our display textnode in the right state so we don't require

two-pass reflow (which printing can't handle) to display comboboxes right. Bug
311380, r+sr=roc


git-svn-id: svn://10.0.0.236/trunk@182658 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bzbarsky%mit.edu
2005-10-20 23:19:22 +00:00
parent 141578e301
commit 148c9f90bb

View File

@@ -2086,8 +2086,10 @@ nsComboboxControlFrame::CreateAnonymousContent(nsPresContext* aPresContext,
if (labelContent) {
// set the value of the text node
mDisplayContent.swap(labelContent);
mDisplayedIndex = -1;
mDisplayedOptionText.Truncate();
mListControlFrame->GetSelectedIndex(&mDisplayedIndex);
if (mDisplayedIndex != -1) {
mListControlFrame->GetOptionText(mDisplayedIndex, mDisplayedOptionText);
}
ActuallyDisplayText(PR_FALSE);
nsCOMPtr<nsINodeInfo> nodeInfo;