GNOME Bugzilla – Bug 705269
power: Add Brightness property for keyboard backlights
Last modified: 2013-08-02 09:00:47 UTC
Necessary for adding it to the Power panel.
Created attachment 250592 [details] [review] power: Add Brightness property for keyboard backlights This changest the return values of the StepUp/StepDown methods to match the return values on the similar screen backlight interface.
Review of attachment 250592 [details] [review]: ::: plugins/power/gsd-power-manager.c @@ +2007,3 @@ /* succeeded, set to -1 since now no old value */ manager->priv->kbd_brightness_old = -1; + value = manager->priv->kbd_brightness_old; Doesn't this change behavior? Previously in this case you would have returned TRUE, but now you return -1.
Created attachment 250614 [details] [review] power: don't return negative value when succeeded This matches the behavior before the previous patch.
Created attachment 250615 [details] [review] power: don't mix printf with GVariant parsing Or we'll segfault trying to parse a string-typed variant for the %s.
Created attachment 250616 [details] [review] power: always use absolute values to set the keyboard brightness The property is a percentage, but we need to pass the absolute value down to upower.
Created attachment 250617 [details] [review] power: use correct return value type We changed this to signed int but forgot to update one location.
Created attachment 250619 [details] [review] media-keys: update for new power plugin DBus API We use signed integers instead of unsigned integers for power percentage now.
Review of attachment 250617 [details] [review]: Yeah
Review of attachment 250614 [details] [review]: Yeah, please merge into the original patch (and change the authorship ;)
Review of attachment 250615 [details] [review]: Definitely yes, but could you please merge the fix before this patchset? It was already broken before my patch.
Review of attachment 250616 [details] [review]: Yep, please merge into previous patch.
Review of attachment 250619 [details] [review]: Yep.
Attachment 250592 [details] pushed as 5614e2c - power: Add Brightness property for keyboard backlights Attachment 250616 [details] pushed as f79014f - power: always use absolute values to set the keyboard brightness Attachment 250619 [details] pushed as 42485c0 - media-keys: update for new power plugin DBus API Squashed and pushed to master, thanks