From 1aaa72b2c972e1a983b6e5736128fba83f3da0b3 Mon Sep 17 00:00:00 2001 From: "martijn.martijn%gmail.com" Date: Wed, 19 Jul 2006 12:06:54 +0000 Subject: [PATCH] Bug 343165 - Make debug.js appear everywhere, patch by Dave Townsend (Mossop), r=mconnor --- browser/base/content/browser.js | 1 - toolkit/content/debug.js | 5 ++--- toolkit/content/globalOverlay.js | 2 ++ 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/browser/base/content/browser.js b/browser/base/content/browser.js index 8c11abefc6e..a1050f51ac6 100644 --- a/browser/base/content/browser.js +++ b/browser/base/content/browser.js @@ -6676,7 +6676,6 @@ var BrowserController = { window.controllers.appendController(BrowserController); #include browser-places.js -#include ../../../toolkit/content/debug.js #endif diff --git a/toolkit/content/debug.js b/toolkit/content/debug.js index 4b631372ff5..45da5c07bc6 100644 --- a/toolkit/content/debug.js +++ b/toolkit/content/debug.js @@ -42,7 +42,6 @@ # This file contains functions that are useful for debugging purposes from # within JavaScript code. -const NS_ASSERT_ENVIRONMENT_VARIABLE_NAME = "XUL_ASSERT_PROMPT"; var gTraceOnAssert = true; /** @@ -89,8 +88,8 @@ function NS_ASSERT(condition, message) { var environment = Components.classes["@mozilla.org/process/environment;1"]. getService(Components.interfaces.nsIEnvironment); - if (environment.exists(NS_ASSERT_ENVIRONMENT_VARIABLE_NAME) && - !parseInt(environment.get(NS_ASSERT_ENVIRONMENT_VARIABLE_NAME))) + if (environment.exists("XUL_ASSERT_PROMPT") && + !parseInt(environment.get("XUL_ASSERT_PROMPT"))) return; var source = null; diff --git a/toolkit/content/globalOverlay.js b/toolkit/content/globalOverlay.js index 5e847efdddb..d2463608cfe 100644 --- a/toolkit/content/globalOverlay.js +++ b/toolkit/content/globalOverlay.js @@ -256,3 +256,5 @@ function FillInTooltip ( tipElement ) } return retVal; } + +#include debug.js