Closed Bug 1705582 Opened 4 years ago Closed 4 years ago

No popuphiding/popuphidden event if a native context menu is hidden before the popupshown event

Categories

(Core :: Widget: Cocoa, defect)

All
macOS
defect

Tracking

()

RESOLVED FIXED
89 Branch
Tracking Status
firefox89 --- fixed

People

(Reporter: mstange, Assigned: mstange)

References

Details

(Whiteboard: [proton-context-menus][mac:mr1])

Attachments

(1 file)

Similar problem to bug 1704215, but with a slightly different set of circumstances.

We have some tests which call menupopup.openPopupAtScreen(...) and menupopup.hidePopup() without waiting for the popupshown event in between. Under those circumstances, the native menu doesn't get far enough in its opening sequence to know that it should fire popuphiding/popuphidden when it is closed.

This is causing a test failure in devtools/client/netmonitor/test/browser_net_columns_last_column.js: Since the old popup never fires popuphidden, this cleanup in devtools/client/framework/menu.js never happens, and old remnant popup nodes are left in the DOM. Those old nodes then confuse the testLastMenuItem check which looks at an old DOM node.

Pushed by mstange@themasta.com: https://hg.mozilla.org/integration/autoland/rev/0c99c4097d7e Make sure NativeMenuMac::Close fires popuphiding / popuphidden even if the menu wasn't fully opened. r=harry
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 89 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: