michael@0: #if 0 michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: #endif michael@0: michael@0: XPCOMUtils.defineLazyModuleGetter(this, "console", michael@0: "resource://gre/modules/devtools/Console.jsm"); michael@0: michael@0: let gDebug = false; michael@0: try { michael@0: gDebug = Services.prefs.getBoolPref(kPrefCustomizationDebug); michael@0: } catch (e) {} michael@0: michael@0: function LOG(...args) { michael@0: if (gDebug) { michael@0: args.unshift(gModuleName); michael@0: console.log.apply(console, args); michael@0: } michael@0: } michael@0: michael@0: function ERROR(...args) { michael@0: args.unshift(gModuleName); michael@0: console.error.apply(console, args); michael@0: } michael@0: michael@0: function INFO(...args) { michael@0: args.unshift(gModuleName); michael@0: console.info.apply(console, args); michael@0: } michael@0: