remove all docshell and webshell usage from cocoa widgets. b=273812 r=cbarrett sr=bz a=roc

git-svn-id: svn://10.0.0.236/trunk@236097 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
joshmoz%gmail.com
2007-09-17 15:07:00 +00:00
parent 27dd171282
commit 188f4d813a
9 changed files with 31 additions and 85 deletions

View File

@@ -494,7 +494,7 @@ nsWebShellWindow::HandleEvent(nsGUIEvent *aEvent)
}
#ifdef USE_NATIVE_MENUS
static void LoadNativeMenus(nsIDOMDocument *aDOMDoc, nsIWidget *aParentWindow, nsIDocShell *aDocShell)
static void LoadNativeMenus(nsIDOMDocument *aDOMDoc, nsIWidget *aParentWindow)
{
// Find the menubar tag (if there is more than one, we ignore all but
// the first).
@@ -519,7 +519,7 @@ static void LoadNativeMenus(nsIDOMDocument *aDOMDoc, nsIWidget *aParentWindow, n
// fake event
nsMenuEvent fake(PR_TRUE, 0, nsnull);
menuListener->MenuConstruct(fake, aParentWindow, menubarNode, aDocShell);
menuListener->MenuConstruct(fake, aParentWindow, menubarNode);
}
#endif
@@ -608,9 +608,7 @@ nsWebShellWindow::OnStateChange(nsIWebProgress *aProgress,
///////////////////////////////
nsCOMPtr<nsIDOMDocument> menubarDOMDoc(GetNamedDOMDoc(NS_LITERAL_STRING("this"))); // XXX "this" is a small kludge for code reused
if (menubarDOMDoc)
{
LoadNativeMenus(menubarDOMDoc, mWindow, mDocShell);
}
LoadNativeMenus(menubarDOMDoc, mWindow);
#endif // USE_NATIVE_MENUS
OnChromeLoaded();