Clicking SyncMenuApp's 'paused' button causes feedback loop if >1 indicator running

Bug #1051798 reported by Charles Kerr
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
The Sync Menu
Fix Released
Low
Charles Kerr

Bug Description

Reported by mterry in IRC.

Behavior: if you have more than one sync indicator running, toggling one of the checkboxes will cause a feedback loop s.t. the same checkbox in the different indicator flickers for a few seconds or more.

(1) User clicks a checkbox in menu A. (2) Dbusmenu's client code listens for the GtkWidget's "activate" signal and propagates it up to the service, where (3) app-menu-item.c gets an "activate" callback, and toggles the SyncMenuApp's "paused" property based on the negated value of DbusmenuMenuitem's TOGGLED property. (4) The SyncMenuApp skeleton's "paused" state is set. (5) Back in the service, app-menu-item.c is listening for SyncMenuApp notify::paused signals, where it toggles DbusmenuMenuitem's TOGGLED property. (5) Dbusmenu sends that property change down to the clients, where our sync-indicator updates its GtkCheckMenuItem's "active" property from DbusmenuMenuitem's TOGGLED property. This is fine because the "active" property is already this value when the user clicked it in step 1.

But, if there are two indicators loaded... menu B's "active" property WILL get changed by step 5, causing an "activate" signal to be emitted, causing steps 2-5 to be repeated, followed by menu A's "active" property being changed, causing a new "activate" signal and steps 2-5 to be repeated again, and so on.

Related branches

Revision history for this message
Charles Kerr (charlesk) wrote :

Setting importance as Low because it's unlikely that end users will have two sync indicators loaded at once.

Charles Kerr (charlesk)
Changed in indicator-sync:
status: In Progress → Fix Committed
Charles Kerr (charlesk)
Changed in indicator-sync:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.