diff --git a/dom/base/nsGlobalWindow.cpp b/dom/base/nsGlobalWindow.cpp index 3a3049bfe34..21cafa56c82 100644 --- a/dom/base/nsGlobalWindow.cpp +++ b/dom/base/nsGlobalWindow.cpp @@ -457,8 +457,6 @@ nsGlobalWindow::DOMMinTimeoutValue() const { // CIDs static NS_DEFINE_CID(kXULControllersCID, NS_XULCONTROLLERS_CID); -static const char sPopStatePrefStr[] = "browser.history.allowPopState"; - #define NETWORK_UPLOAD_EVENT_NAME NS_LITERAL_STRING("moznetworkupload") #define NETWORK_DOWNLOAD_EVENT_NAME NS_LITERAL_STRING("moznetworkdownload") @@ -9917,11 +9915,6 @@ nsGlobalWindow::DispatchSyncPopState() NS_ASSERTION(nsContentUtils::IsSafeToRunScript(), "Must be safe to run script here."); - // Check that PopState hasn't been pref'ed off. - if (!Preferences::GetBool(sPopStatePrefStr, false)) { - return NS_OK; - } - nsresult rv = NS_OK; // Bail if the window is frozen. diff --git a/dom/base/nsHistory.cpp b/dom/base/nsHistory.cpp index a320743429d..3459df4b0cc 100644 --- a/dom/base/nsHistory.cpp +++ b/dom/base/nsHistory.cpp @@ -25,11 +25,6 @@ using namespace mozilla; using namespace mozilla::dom; -static const char* sAllowPushStatePrefStr = - "browser.history.allowPushState"; -static const char* sAllowReplaceStatePrefStr = - "browser.history.allowReplaceState"; - // // History class implementation // @@ -304,12 +299,6 @@ nsHistory::PushOrReplaceState(JSContext* aCx, JS::Handle aData, return; } - // Check that PushState hasn't been pref'ed off. - if (!Preferences::GetBool(aReplace ? sAllowReplaceStatePrefStr : - sAllowPushStatePrefStr, false)) { - return; - } - // AddState might run scripts, so we need to hold a strong reference to the // docShell here to keep it from going away. nsCOMPtr docShell = win->GetDocShell(); diff --git a/modules/libpref/init/all.js b/modules/libpref/init/all.js index 391c79b5977..b765cb10dbc 100644 --- a/modules/libpref/init/all.js +++ b/modules/libpref/init/all.js @@ -4486,9 +4486,6 @@ pref("html5.flushtimer.initialdelay", 120); pref("html5.flushtimer.subsequentdelay", 120); // Push/Pop/Replace State prefs -pref("browser.history.allowPushState", true); -pref("browser.history.allowReplaceState", true); -pref("browser.history.allowPopState", true); pref("browser.history.maxStateObjectSize", 655360); pref("browser.meta_refresh_when_inactive.disabled", false);