32 const Cc = Components.classes;
33 const Ci = Components.interfaces;
34 const Cr = Components.results
41 let environment =
Cc[
"@mozilla.org/process/environment;1"]
42 .createInstance(
Ci.nsIEnvironment);
43 let result = environment.get(
"NSPR_LOG_MODULES");
47 return this.logModules;
61 generateLogFunction:
function DebugUtils_generateLogFunction(
module, level) {
67 for each (let
entry in this.logModules.split(/,/)) {
68 if (/(.*):(
\d+)$/.
test(entry) &&
69 (RegExp.$1 ==
module || RegExp.$1 ==
"all") &&
70 parseInt(RegExp.$2) >= minLevel) {
81 return function LOG(
msg) {};
return!aWindow arguments!aWindow arguments[0]
__defineGetter__("Application", function(){delete this.Application;return this.Application=Cc["@mozilla.org/fuel/application;1"].getService(Ci.fuelIApplication);})