зеркало из https://github.com/mozilla/pjs.git
Bug 348497: Crash enabling designMode
r+sr=bzbarsky
This commit is contained in:
Родитель
fb58e3763b
Коммит
e5a0f6e2fe
|
@ -329,6 +329,13 @@ nsEditingSession::SetupEditorOnWindow(nsIDOMWindow *aWindow)
|
|||
mimeCType.AssignLiteral("text/html");
|
||||
}
|
||||
}
|
||||
|
||||
// Flush out frame construction to make sure that the subframe's
|
||||
// presshell is set up if it needs to be.
|
||||
nsCOMPtr<nsIDocument> document(do_QueryInterface(doc));
|
||||
if (document) {
|
||||
document->FlushPendingNotifications(Flush_Frames);
|
||||
}
|
||||
}
|
||||
PRBool needHTMLController = PR_FALSE;
|
||||
|
||||
|
@ -389,13 +396,6 @@ nsEditingSession::SetupEditorOnWindow(nsIDOMWindow *aWindow)
|
|||
nsIDocShell *docShell = GetDocShellFromWindow(aWindow);
|
||||
if (!docShell) return NS_ERROR_FAILURE;
|
||||
|
||||
// Flush out frame construction to make sure that the subframe's
|
||||
// presshell is set up if it needs to be.
|
||||
nsCOMPtr<nsIDocument> document(do_QueryInterface(doc));
|
||||
if (document) {
|
||||
document->FlushPendingNotifications(Flush_Frames);
|
||||
}
|
||||
|
||||
// Disable animation of images in this document:
|
||||
nsCOMPtr<nsIDOMWindowUtils> utils(do_GetInterface(aWindow));
|
||||
if (!utils) return NS_ERROR_FAILURE;
|
||||
|
|
Загрузка…
Ссылка в новой задаче