Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Issue 5809: Firebug triggers Firefox crash on Ubuntu since the fix fo…

…r issue 5427
  • Loading branch information...
commit 435d32f423995a9b7397926a7e771a7bf96ff605 1 parent 7ad441f
Jan Odvarko authored August 14, 2012
4  extension/content/firebug/firebugOverlay.xul
@@ -62,8 +62,8 @@
62 62
                                 <image src="chrome://firebug/skin/firebug.png"/>
63 63
 
64 64
                                 <menupopup id="menu_firebug_iconMenu" class="fbFirebugMenuPopup"
65  
-                                    onpopupshowing="return Firebug.GlobalUI.onMenuShowing(this);"
66  
-                                    onpopuphiding="return Firebug.GlobalUI.onMenuHiding(this);">
  65
+                                    onpopupshowing="return Firebug.GlobalUI.onMenuShowing(this, event);"
  66
+                                    onpopuphiding="return Firebug.GlobalUI.onMenuHiding(this, event);">
67 67
                                     <!-- Content comes from firebugMenuContent -->
68 68
                                 </menupopup>
69 69
                             </toolbarbutton>
20  extension/content/firebug/firefox/browserOverlay.js
@@ -374,10 +374,10 @@ Firebug.GlobalUI =
374 374
         PrefLoader.setPref(option, checked);
375 375
     },
376 376
 
377  
-    onMenuShowing: function(popup)
  377
+    onMenuShowing: function(popup, event)
378 378
     {
379  
-        // If this popup is already open the event comes from a sub menu, just ignore it.
380  
-        if (popup.state == "open")
  379
+        // If the event comes from a sub menu, just ignore it.
  380
+        if (popup != event.target)
381 381
             return;
382 382
 
383 383
         while (popup.lastChild)
@@ -451,7 +451,7 @@ Firebug.GlobalUI =
451 451
 
452 452
     onMenuHiding: function(popup)
453 453
     {
454  
-        if (popup.state == "open")
  454
+        if (popup != event.target)
455 455
             return;
456 456
 
457 457
         // xxxHonza: I don't know why the timeout must be here, but if it isn't
@@ -1072,8 +1072,8 @@ $menupopupOverlay($("menuWebDeveloperPopup"), [
1072 1072
         $menupopup({
1073 1073
             id: "menu_firebug_firebugMenuPopup",
1074 1074
             "class": "fbFirebugMenuPopup",
1075  
-            onpopupshowing: "return Firebug.GlobalUI.onMenuShowing(this);",
1076  
-            onpopuphiding: "return Firebug.GlobalUI.onMenuHiding(this);"
  1075
+            onpopupshowing: "return Firebug.GlobalUI.onMenuShowing(this, event);",
  1076
+            onpopuphiding: "return Firebug.GlobalUI.onMenuHiding(this, event);"
1077 1077
         })
1078 1078
     ]),
1079 1079
     $menuseparator({
@@ -1095,8 +1095,8 @@ $menupopupOverlay($("appmenu_webDeveloper_popup"), [
1095 1095
         $menupopup({
1096 1096
             id: "appmenu_firebugMenuPopup",
1097 1097
             "class": "fbFirebugMenuPopup",
1098  
-            onpopupshowing: "return Firebug.GlobalUI.onMenuShowing(this);",
1099  
-            onpopuphiding: "return Firebug.GlobalUI.onMenuHiding(this);"
  1098
+            onpopupshowing: "return Firebug.GlobalUI.onMenuShowing(this, event);",
  1099
+            onpopuphiding: "return Firebug.GlobalUI.onMenuHiding(this, event);"
1100 1100
         })
1101 1101
     ]),
1102 1102
     $menuseparator({
@@ -1117,8 +1117,8 @@ $menupopupOverlay($("toolsPopup"), [
1117 1117
         $menupopup({
1118 1118
             id: "toolsmenu_firebugMenuPopup",
1119 1119
             "class": "fbFirebugMenuPopup",
1120  
-            onpopupshowing: "return Firebug.GlobalUI.onMenuShowing(this);",
1121  
-            onpopupshowing: "return Firebug.GlobalUI.onMenuHiding(this);"
  1120
+            onpopupshowing: "return Firebug.GlobalUI.onMenuShowing(this, event);",
  1121
+            onpopupshowing: "return Firebug.GlobalUI.onMenuHiding(this, event);"
1122 1122
         })
1123 1123
     ])
1124 1124
 ]);

0 notes on commit 435d32f

Please sign in to comment.
Something went wrong with that request. Please try again.