New bie question on listening events

10 views
Skip to first unread message

Ravi

unread,
Feb 23, 2012, 9:33:58 PM2/23/12
to Firebug
Hello,

I am creating extension based on firebug. I would like to observe the
following event and change the innerRow style. How do i do that?

Here is my sample code:

http://pastebin.com/Js7ANzSb



console.js -
dispatch([Firebug.A11yModel], 'onLogRowCreated', [this,
innerRow]);

Any doc on how listeners/observers/notifiers in firebug would be
great.

Thanks,
Ravi

Jan Honza Odvarko

unread,
Feb 24, 2012, 7:14:19 AM2/24/12
to fir...@googlegroups.com
What Firebug version do you use?

in 1.10 I am seeing (console.js):

Events.dispatch(this.fbListeners, "onLogRowCreated", [panel , row]);

Which means that the event will be dispatched to all listeners registered in

Firebug.Console

Example:

Firebug.Console.addListener(listener);
Firebug.Console.removeListener(listener);

var listener =
{
    onLogRowCreated: function(panel, row)  
    {
    }
}

See some docs here:
http://getfirebug.com/wiki/index.php/Extension_Points#Console_Listener

Another example of net panel listener:
http://www.softwareishard.com/blog/firebug-tutorial/extending-firebug-net-panel-listener-part-viii/

Honza

Ravi

unread,
Feb 27, 2012, 1:45:37 PM2/27/12
to Firebug
Thanks a lot. I am using Firebug 1.5. I should probably upgrade to
firebug 1.10 and make the code changes accordingly. Thanks a lot
Honza.

Regards,
Ravi
> Another example of net panel listener:http://www.softwareishard.com/blog/firebug-tutorial/extending-firebug...
>
> Honza
Reply all
Reply to author
Forward
0 new messages