Closed Bug 1757402 Opened 9 months ago Closed 9 months ago

Add native context menu support on GTK

Categories

(Core :: Widget: Gtk, task)

task

Tracking

()

RESOLVED FIXED
99 Branch
Tracking Status
firefox99 --- fixed

People

(Reporter: emilio, Assigned: emilio)

References

(Depends on 2 open bugs, Blocks 1 open bug)

Details

Attachments

(1 file)

I had this written somewhere in a branch, but given bug 1419151, I cleaned it up a bit and turned it into an actual patch that works.

Behind a pref for now, because at the very least it needs:

  • Support for some testing-only functions.
  • Support for custom icons (for web extensions and so on).

But the key point is that this adds the relevant code to map a XUL menu to a GMenuModel, which we could then export via g_dbus_connection_export_menu_model(), which seems like a much simpler approach to support stuff like bug 1419151, see the MenuModel class in NativeMenuGtk.

I had this written somewhere in a branch, but given bug 1419151, I
cleaned it up a bit and turned it into an actual patch that works.

Behind a pref for now, because at the very least it needs:

  • Support for some testing-only functions.
  • Support for custom icons (for web extensions and so on).

The key point is that this adds the relevant code to map a XUL menu to a
GMenuModel, which we could then export via
g_dbus_connection_export_menu_model(), which seems like a much simpler
approach to support stuff like bug 1419151.

See the MenuModel class in NativeMenuGtk as for how is this done.

Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/82a2af7ebe33
Add basic native context menu support on GTK. r=stransky
Status: NEW → RESOLVED
Closed: 9 months ago
Resolution: --- → FIXED
Target Milestone: --- → 99 Branch
Depends on: 1758424, 1758425
Depends on: 1759950
Depends on: 1759952
Depends on: 1775116
Depends on: 1782533
You need to log in before you can comment on or make changes to this bug.