[gnome-settings-daemon/docking-stations] Tell the xrandr plugin when the lid's state changes
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-settings-daemon/docking-stations] Tell the xrandr plugin when the lid's state changes
- Date: Tue, 22 Nov 2011 23:24:52 +0000 (UTC)
commit d86a6274ada9e93a669debfe6ae1fa0b7e2120d0
Author: Federico Mena Quintero <federico gnome org>
Date: Tue Nov 22 12:09:53 2011 -0600
Tell the xrandr plugin when the lid's state changes
Signed-off-by: Federico Mena Quintero <federico gnome org>
plugins/power/gsd-power-manager.c | 11 +++++++++++
1 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/plugins/power/gsd-power-manager.c b/plugins/power/gsd-power-manager.c
index 0934cdb..99a1214 100644
--- a/plugins/power/gsd-power-manager.c
+++ b/plugins/power/gsd-power-manager.c
@@ -2172,6 +2172,17 @@ up_client_changed_cb (UpClient *client, GsdPowerManager *manager)
return;
manager->priv->lid_is_closed = tmp;
+ /* tell the RANDR plugin to update its state; the display on the lid needs to be turned off */
+ if (manager->priv->xrandr_internal_proxy != NULL) {
+ g_dbus_proxy_call_sync (manager->priv->xrandr_internal_proxy,
+ "LidStateChanged",
+ NULL, /* parameters */
+ G_DBUS_CALL_FLAGS_NONE, /* flags */
+ -1, /* timeout */
+ NULL, /* cancellable */
+ NULL); /* NULL-GError */
+ }
+
/* fake a keypress */
if (tmp)
do_lid_closed_action (manager);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]