summaryrefslogtreecommitdiff
path: root/plugins/power
diff options
context:
space:
mode:
authorCosimo Cecchi <cosimoc@gnome.org>2014-11-13 10:23:24 -0800
committerCosimo Cecchi <cosimoc@gnome.org>2014-11-13 10:28:06 -0800
commit5c17bd05f7d189ec97cd76b169f5888fc60374c8 (patch)
tree9334e589209cd8685dfe695cefe9cf736dc979ee /plugins/power
parenta653c34b468f5f42f42832e887f10ba4dd4bae98 (diff)
downloadgnome-settings-daemon-5c17bd05f7d189ec97cd76b169f5888fc60374c8.tar.gz
power: return output id when changing screen brightness
When StepUp() or StepDown() are called to change the screen brightness, also return the output id where the brightness transition happened (if any). This is useful so that the shell can show the OSD only on the relevant monitor, which will be done in the next commit. https://bugzilla.gnome.org/show_bug.cgi?id=704086
Diffstat (limited to 'plugins/power')
-rw-r--r--plugins/power/gsd-power-manager.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/plugins/power/gsd-power-manager.c b/plugins/power/gsd-power-manager.c
index 0c2469d2..13c34f38 100644
--- a/plugins/power/gsd-power-manager.c
+++ b/plugins/power/gsd-power-manager.c
@@ -83,9 +83,11 @@ static const gchar introspection_xml[] =
" <property name='Brightness' type='i' access='readwrite'/>"
" <method name='StepUp'>"
" <arg type='i' name='new_percentage' direction='out'/>"
+" <arg type='i' name='output_id' direction='out'/>"
" </method>"
" <method name='StepDown'>"
" <arg type='i' name='new_percentage' direction='out'/>"
+" <arg type='i' name='output_id' direction='out'/>"
" </method>"
" </interface>"
" <interface name='org.gnome.SettingsDaemon.Power.Keyboard'>"
@@ -2609,8 +2611,9 @@ out:
error);
} else {
g_dbus_method_invocation_return_value (invocation,
- g_variant_new ("(i)",
- value));
+ g_variant_new ("(ii)",
+ value,
+ backlight_get_output_id (manager->priv->rr_screen)));
}
}