deCOMtaminate nsIDocument by changing methods to use return value instead of out-params, eliminating unused nsresult return values, moving some members to nsIDocument and inlining the getters/setters. Bug 222134, r=bzbarsky, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@148257 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -928,8 +928,6 @@ nsMenuPopupFrame::SyncViewWithFrame(nsIPresContext* aPresContext,
|
||||
aPresContext->GetShell(getter_AddRefs(presShell));
|
||||
nsCOMPtr<nsIDocument> document;
|
||||
presShell->GetDocument(getter_AddRefs(document));
|
||||
nsCOMPtr<nsIScriptGlobalObject> scriptGlobalObject;
|
||||
document->GetScriptGlobalObject(getter_AddRefs(scriptGlobalObject));
|
||||
|
||||
nsCOMPtr<nsIAtom> tag;
|
||||
mContent->GetTag(getter_AddRefs(tag));
|
||||
@@ -986,7 +984,7 @@ nsMenuPopupFrame::SyncViewWithFrame(nsIPresContext* aPresContext,
|
||||
// Compute info about the screen dimensions. Because of multiple monitor systems,
|
||||
// the left or top sides of the screen may be in negative space (main monitor is on the
|
||||
// right, etc). We need to be sure to do the right thing.
|
||||
nsCOMPtr<nsIDOMWindowInternal> window(do_QueryInterface(scriptGlobalObject));
|
||||
nsCOMPtr<nsIDOMWindowInternal> window(do_QueryInterface(document->GetScriptGlobalObject()));
|
||||
nsCOMPtr<nsIDOMScreen> screen;
|
||||
window->GetScreen(getter_AddRefs(screen));
|
||||
PRInt32 screenWidth = 0, screenHeight = 0;
|
||||
|
||||
Reference in New Issue
Block a user