small performance improvement. weeded out some obsolete code that was

causing round trips through the editor unnecessarily.
thanks for pointing out the problem, akkana and bruce m.


git-svn-id: svn://10.0.0.236/trunk@48310 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
buster%netscape.com
1999-09-20 03:59:43 +00:00
parent 9d1c6f186b
commit 2e2ab230d1

View File

@@ -1540,18 +1540,10 @@ nsGfxTextControlFrame::InitializeTextControl(nsIPresShell *aPresShell, nsIDOMDoc
return result;
}
// this is where we'll propogate a state changed event, once hyatt defines it.
NS_IMETHODIMP
nsGfxTextControlFrame::InternalContentChanged()
{
if (!IsInitialized()) { return NS_ERROR_NOT_INITIALIZED; }
nsAutoString textValue;
// XXX: need to check here if we're an HTML edit field or a text edit field
nsString format ("text/plain");
mEditor->OutputToString(textValue, format, 0);
if (IsSingleLineTextControl()) {
RemoveNewlines(textValue);
}
SetTextControlFrameState(textValue); // set new text value
return NS_OK;
}