equal
deleted
inserted
replaced
|
1 /** |
|
2 * This class provides access to the debugging console. |
|
3 * @constructor |
|
4 */ |
|
5 function DebugConsole() { |
|
6 } |
|
7 |
|
8 /** |
|
9 * Print a normal log message to the console |
|
10 * @param {Object|String} message Message or object to print to the console |
|
11 */ |
|
12 DebugConsole.prototype.log = function(message) { |
|
13 |
|
14 //This ends up in C:\jslog_widget.log on the device |
|
15 console.log(message); |
|
16 }; |
|
17 |
|
18 /** |
|
19 * Print a warning message to the console |
|
20 * @param {Object|String} message Message or object to print to the console |
|
21 */ |
|
22 DebugConsole.prototype.warn = function(message) { |
|
23 }; |
|
24 |
|
25 /** |
|
26 * Print an error message to the console |
|
27 * @param {Object|String} message Message or object to print to the console |
|
28 */ |
|
29 DebugConsole.prototype.error = function(message) { |
|
30 }; |
|
31 |
|
32 if (typeof window.debug == "undefined") window.debug = new DebugConsole(); |