Bug 118704. Get the document title from the DOM instead of storing it in the document object. Relanding with hopeful leak fix. r+sr=jst

This commit is contained in:
Robert O'Callahan
2008-08-18 14:10:28 +12:00
parent e4ae445e82
commit 49dbf21392
26 changed files with 465 additions and 254 deletions
+2 -6
View File
@@ -5897,13 +5897,9 @@ nsDocShell::RestoreFromHistory()
rv = privWin->RestoreWindowState(windowState);
NS_ENSURE_SUCCESS(rv, rv);
// Now, dispatch a title change event which would happed as the
// Now, dispatch a title change event which would happen as the
// <head> is parsed.
nsCOMPtr<nsIDOMNSDocument> nsDoc = do_QueryInterface(document);
if (nsDoc) {
const nsAFlatString &title = document->GetDocumentTitle();
nsDoc->SetTitle(title);
}
document->NotifyPossibleTitleChange(PR_FALSE);
// Now we simulate appending child docshells for subframes.
for (i = 0; i < childShells.Count(); ++i) {