My favorites | Sign in
Project Home Wiki Issues
New issue   Search
for
  Advanced search   Search tips   Subscriptions
Issue 5854: Enable + disable of options doesn't always take effect
1 person starred this issue and may be notified of changes. Back to list
Status:  Fixed
Owner:  simon.lindholm10
Closed:  Aug 2012
Cc:  odva...@gmail.com


Sign in to add a comment
 
Project Member Reported by simon.lindholm10, Aug 21, 2012
What steps will reproduce the problem?
1. Right-click <body> in the HTML panel.
2. Click "Log Events". Because this is a checkbox item, the context menu stays open (for me, at least).
3. Click it again to turn it off.

What is the expected output? What do you see instead?
"Log Events" should be turned off, but is not (it fails because as generated in getContextMenuItems, "Log Events" turns event logging on).

Honza, can I change EventMonitor.toggleMonitorEvents to not take a "state" argument and instead pretend 'state = this.areEventsMonitored(object, types, context)' within the function? Firebug extensions make me paranoid, and I'm never sure how much API things I can change.
Aug 21, 2012
Project Member #1 odva...@gmail.com
Yeah, I have sometimes the same feeling ;-)

I think that changing the argument list is ok in this case, but you can also fix it as follows:

{
    label: "ShowEventsInConsole",
    tooltiptext: "html.tip.Show_Events_In_Console",
    id: "fbShowEventsInConsole",
    type: "checkbox",
    checked: monitored,
    command: function() {
        var monitored = EventMonitor.areEventsMonitored(elt, null, context);
        EventMonitor.toggleMonitorEvents(elt, null, monitored, context);
    }
},

Btw. I am a little worried if there are more menus broken this way.

Honza

Aug 22, 2012
Project Member #2 simon.lindholm10
> Btw. I am a little worried if there are more menus broken this way.
This hunch was very much correct. I think I caught everything:
https://github.com/firebug/firebug/commit/3beb0c78cde97ba1ac6be42f28669bd92506eef6
Summary: Enable + disable of options doesn't always take effect
Status: Commit
Owner: simon.lindholm10
Labels: -html -console
Aug 22, 2012
Project Member #3 odva...@gmail.com
OK, great!

Honz
Aug 24, 2012
Project Member #4 odva...@gmail.com
This issue has been fixed in Firebug 1.11.0a2
https://getfirebug.com/releases/firebug/1.11/firebug-1.11.0a2.xpi

Please check it out and let us know if it works for you.

Thanks for the help!
Honza

Status: Fixed
Labels: fixed-1.11-a2
Sign in to add a comment

Powered by Google Project Hosting