From d4bc9306c69f64bdabe48d18eaa72c4a22c7fef4 Mon Sep 17 00:00:00 2001 From: "rods%netscape.com" Date: Wed, 10 Feb 1999 16:25:11 +0000 Subject: [PATCH] Added GetWebShell method --- dom/src/base/nsGlobalWindow.cpp | 12 ++++++++++++ dom/src/base/nsGlobalWindow.h | 1 + 2 files changed, 13 insertions(+) diff --git a/dom/src/base/nsGlobalWindow.cpp b/dom/src/base/nsGlobalWindow.cpp index a5443a89648b..b754732795e0 100644 --- a/dom/src/base/nsGlobalWindow.cpp +++ b/dom/src/base/nsGlobalWindow.cpp @@ -248,6 +248,18 @@ GlobalWindowImpl::SetWebShell(nsIWebShell *aWebShell) } } +NS_IMETHODIMP_(void) // XXX This may be temporary - rods +GlobalWindowImpl::GetWebShell(nsIWebShell **aWebShell) +{ + if (nsnull != mWebShell) { + *aWebShell = mWebShell; + NS_ADDREF(mWebShell); + } else { + //*mWebShell = nsnull; + } + +} + NS_IMETHODIMP_(void) GlobalWindowImpl::SetOpenerWindow(nsIDOMWindow *aOpener) { diff --git a/dom/src/base/nsGlobalWindow.h b/dom/src/base/nsGlobalWindow.h index 114d47bd5e49..14e87ee27d00 100644 --- a/dom/src/base/nsGlobalWindow.h +++ b/dom/src/base/nsGlobalWindow.h @@ -65,6 +65,7 @@ public: NS_IMETHOD_(void) SetContext(nsIScriptContext *aContext); NS_IMETHOD_(void) SetNewDocument(nsIDOMDocument *aDocument); NS_IMETHOD_(void) SetWebShell(nsIWebShell *aWebShell); + NS_IMETHOD_(void) GetWebShell(nsIWebShell **aWebShell);// XXX This may be temporary - rods NS_IMETHOD_(void) SetOpenerWindow(nsIDOMWindow *aOpener); NS_IMETHOD GetWindow(nsIDOMWindow** aWindow);