diff options
-rw-r--r-- | dom/base/nsGlobalWindow.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/dom/base/nsGlobalWindow.cpp b/dom/base/nsGlobalWindow.cpp index 0587eb892..dd1fe4586 100644 --- a/dom/base/nsGlobalWindow.cpp +++ b/dom/base/nsGlobalWindow.cpp @@ -14456,6 +14456,20 @@ nsGlobalChromeWindow::TakeOpenerForInitialContentBrowser(mozIDOMWindowProxy** aO return NS_OK; } +/* static */ already_AddRefed<nsGlobalWindow> +nsGlobalWindow::Create(nsGlobalWindow *aOuterWindow) +{ + RefPtr<nsGlobalWindow> window = new nsGlobalWindow(aOuterWindow); + window->InitWasOffline(); + return window.forget(); +} + +void +nsGlobalWindow::InitWasOffline() +{ + mWasOffline = NS_IsOffline(); +} + #if defined(MOZ_WIDGET_ANDROID) int16_t nsGlobalWindow::Orientation(CallerType aCallerType) const |