Skip to content

(cherry-pick) applets/brightness: Make brightness of multiple applets stay in sync

Cherry-pick MR for !462 (merged).


Previously, dragging the slider on one instance of the applet would leave other instances untouched and thus out of sync. The sending applet instance would include a hardcoded source client context string in its setBrightness D-Bus method call, but all instances would ignore the resulting brightness change event with this context.

To fix this, make sure that each applet instance uses a different context string. We'll increment a number in each constructor and use it as part of a context string template. Only the sending applet instance will ignore brightness change events caused by its own brightness setter call.

BUG: 495661

(cherry picked from commit 5a06866f)

Merge request reports

Loading