| 405 | | var firebug = chromeWin.Firebug.Console; |
|---|
| 406 | | var fbContext = chromeWin.TabWatcher.getContextByWindow(unsafeContentWin); |
|---|
| 407 | | |
|---|
| 408 | | if (!firebug.isEnabled(fbContext)) return null; |
|---|
| 409 | | |
|---|
| 410 | | firebugConsole = {}; |
|---|
| 411 | | var commands = ["log", "debug", "info", "warn", "error"]; |
|---|
| 412 | | commands.forEach(function(command) { |
|---|
| 413 | | firebugConsole[command] = function() { |
|---|
| 414 | | firebug.logFormatted.call( |
|---|
| 415 | | firebug, Array.slice(arguments), firebugContext, command |
|---|
| 416 | | ); |
|---|
| 417 | | } |
|---|
| 418 | | }); |
|---|
| | 405 | if (!chromeWin.Firebug.Console.isEnabled(firebugContext)) { |
|---|
| | 406 | return null; |
|---|
| | 407 | } |
|---|
| | 408 | var FirebugConsoleHandler = eval("FirebugConsoleHandler", chromeWin.Firebug.Console.injector.attachConsole); |
|---|
| | 409 | firebugConsole = new FirebugConsoleHandler(firebugContext, unsafeContentWin); |
|---|