Skip to content

Commit

Permalink
Issue 2258: Custom console log formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
janodvarko committed Jan 8, 2010
1 parent b2e2658 commit b936498
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion extension/content/firebug/console.js
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,9 @@ Firebug.ConsolePanel.prototype = extend(Firebug.ActivablePanel,
if (part && typeof(part) == "object")
{
var object = objects[++objIndex];
if (typeof(object) != "undefined")
if (part.type == "%c")
row.setAttribute("style", object.toString());
else if (typeof(object) != "undefined")
this.appendObject(object, row, part.rep);
else
this.appendObject(part.type, row, FirebugReps.Text);
Expand Down Expand Up @@ -968,6 +970,7 @@ function parseFormat(format)
rep = FirebugReps.Number;
break;
case "o":
case "c":
rep = null;
break;
}
Expand Down

0 comments on commit b936498

Please sign in to comment.