summaryrefslogtreecommitdiff
path: root/dom/base/nsGlobalWindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'dom/base/nsGlobalWindow.cpp')
-rw-r--r--dom/base/nsGlobalWindow.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/dom/base/nsGlobalWindow.cpp b/dom/base/nsGlobalWindow.cpp
index 0587eb8927..dd1fe45862 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