if (editorShell) { editorShell->FinishHTMLSource(); PRBool wasSaved; rv = editorShell->SaveDocument(PR_FALSE, PR_FALSE, &wasSaved); } return rv;
return UpdateCommandState(aCommandName, refCon);
nsSaveCommand::DoCommand(const PRUnichar *aCommand, nsISupports * refCon){  nsCOMPtr<nsIEditorShell> editorShell = do_QueryInterface(refCon);  nsresult rv = NS_OK;    if (editorShell)  {    editorShell->FinishHTMLSource();    PRBool wasSaved;    rv = editorShell->SaveDocument(PR_FALSE, PR_FALSE, &wasSaved);  }  return rv;  }