зеркало из https://github.com/mozilla/pjs.git
DeCOMify GetParent/GetBindingParent/GetDocument on nsIContent. Bug 213823,
r+sr=jst
This commit is contained in:
Родитель
d9677bdddc
Коммит
ddcd064ca2
|
@ -100,10 +100,9 @@ static void GetPrimaryPresShell(nsIFrame* aFrame, nsIPresShell** aResult)
|
|||
if (!aFrame)
|
||||
return;
|
||||
|
||||
nsCOMPtr<nsIDocument> doc;
|
||||
nsCOMPtr<nsIContent> content;
|
||||
aFrame->GetContent(getter_AddRefs(content));
|
||||
content->GetDocument(getter_AddRefs(doc));
|
||||
nsIDocument* doc = content->GetDocument();
|
||||
if (doc)
|
||||
doc->GetShellAt(0, aResult); // Addref happens here.
|
||||
}
|
||||
|
|
|
@ -100,10 +100,9 @@ static void GetPrimaryPresShell(nsIFrame* aFrame, nsIPresShell** aResult)
|
|||
if (!aFrame)
|
||||
return;
|
||||
|
||||
nsCOMPtr<nsIDocument> doc;
|
||||
nsCOMPtr<nsIContent> content;
|
||||
aFrame->GetContent(getter_AddRefs(content));
|
||||
content->GetDocument(getter_AddRefs(doc));
|
||||
nsIDocument* doc = content->GetDocument();
|
||||
if (doc)
|
||||
doc->GetShellAt(0, aResult); // Addref happens here.
|
||||
}
|
||||
|
|
|
@ -307,10 +307,9 @@ static void GetPrimaryPresShell(nsIFrame* aFrame, nsIPresShell** aResult)
|
|||
if (!aFrame)
|
||||
return;
|
||||
|
||||
nsCOMPtr<nsIDocument> doc;
|
||||
nsCOMPtr<nsIContent> content;
|
||||
aFrame->GetContent(getter_AddRefs(content));
|
||||
content->GetDocument(getter_AddRefs(doc));
|
||||
nsIDocument* doc = content->GetDocument);
|
||||
if (doc)
|
||||
doc->GetShellAt(0, aResult); // Addref happens here.
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче