From 51e844ec48f5ad7ffcc98addc428ab4c650dc60a Mon Sep 17 00:00:00 2001 From: jonobr1 Date: Sun, 23 Jan 2011 13:54:09 -0800 Subject: [PATCH] added log method to gui.js --- gui.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/gui.js b/gui.js index b881cd3..af6c010 100644 --- a/gui.js +++ b/gui.js @@ -11,7 +11,7 @@ var GUI = new function() { var handler = addHandlers[type]; if (handler) { } else { - console.error("I don't know how to handle data type: " + type); + log("I don't know how to handle data type: " + type); } } @@ -36,4 +36,11 @@ var GUI = new function() { }; +}; + +// Now we don't need to worry about console.log +var log = function(item) { + if(window.console) + if(trim(window.console.firebug) != '') + console.info(item); }; \ No newline at end of file