Ensure that the style buttons update as soon as you press them, so that the button reflects the type-in state properly.

git-svn-id: svn://10.0.0.236/trunk@68047 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
sfraser%netscape.com
2000-05-03 05:13:59 +00:00
parent ea753b5a87
commit 532a7edf2e
2 changed files with 8 additions and 2 deletions

View File

@@ -141,7 +141,10 @@ nsBaseStateUpdatingCommand::DoCommand(const PRUnichar *aCommand, nsISupports * r
nsCOMPtr<nsIEditorShell> editorShell = do_QueryInterface(refCon);
if (!editorShell) return NS_ERROR_NOT_INITIALIZED;
return ToggleState(editorShell, mTagName);
nsresult rv = ToggleState(editorShell, mTagName);
if (NS_FAILED(rv)) return rv;
return UpdateCommandState(aCommand, refCon);
}
NS_IMETHODIMP

View File

@@ -141,7 +141,10 @@ nsBaseStateUpdatingCommand::DoCommand(const PRUnichar *aCommand, nsISupports * r
nsCOMPtr<nsIEditorShell> editorShell = do_QueryInterface(refCon);
if (!editorShell) return NS_ERROR_NOT_INITIALIZED;
return ToggleState(editorShell, mTagName);
nsresult rv = ToggleState(editorShell, mTagName);
if (NS_FAILED(rv)) return rv;
return UpdateCommandState(aCommand, refCon);
}
NS_IMETHODIMP