Skip to content

GMenuModel exporter: group change signals

The GMenuModel D-Bus protocol has always supported grouping of change signals.

We originally wanted to avoid potentially sending change signals for menus and actions out of sync with each other in order to avoid the case of menuitem being created for an action that did not yet exist on the remote side.

We considered some rather exotic methods of dealing with this out-of-order issue including "reservations" on GDBusConnections for who would send the next message, but they all fell through.

For this reason, the grouping feature of the protocol was never used: we were always sending one event per signal.

As it turns out, the order in which menuitems and actions show up on the remote is not very important so we don't have to worry about this problem anymore. This patch implements the grouping (which is fairly easy because the code was specifically designed for this possibility).

Fixes: #687 (closed)

Edited by Jeff Fortin

Merge request reports