diff options
author | Richard Hughes <richard@hughsie.com> | 2011-01-04 18:05:09 +0000 |
---|---|---|
committer | Richard Hughes <richard@hughsie.com> | 2011-01-04 18:05:09 +0000 |
commit | 17b7aef701c1dfac0376149aba64fbcdde278a32 (patch) | |
tree | ede0820c06e657b0ec57253b70f5e2019a2f99a0 /tools | |
parent | c507b516d47b5eb8b3084efb93b71aaaa92a78c1 (diff) | |
download | upower-17b7aef701c1dfac0376149aba64fbcdde278a32.tar.gz |
linux: use the number of active DRM devices to determine the system docked status
Not ideal, but better than relying on ACPI.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/up-tool.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/up-tool.c b/tools/up-tool.c index 9be5588..9156010 100644 --- a/tools/up-tool.c +++ b/tools/up-tool.c @@ -124,6 +124,7 @@ up_client_print (UpClient *client) gboolean on_low_battery; gboolean lid_is_closed; gboolean lid_is_present; + gboolean is_docked; g_object_get (client, "daemon-version", &daemon_version, @@ -133,6 +134,7 @@ up_client_print (UpClient *client) "on-low_battery", &on_low_battery, "lid-is-closed", &lid_is_closed, "lid-is-present", &lid_is_present, + "is-docked", &is_docked, NULL); g_print (" daemon-version: %s\n", daemon_version); @@ -141,7 +143,8 @@ up_client_print (UpClient *client) g_print (" on-battery: %s\n", on_battery ? "yes" : "no"); g_print (" on-low-battery: %s\n", on_low_battery ? "yes" : "no"); g_print (" lid-is-closed: %s\n", lid_is_closed ? "yes" : "no"); - g_print (" lid-is-present: %s\n", lid_is_present ? "yes" : "no"); + g_print (" lid-is-present: %s\n", lid_is_present ? "yes" : "no"); + g_print (" is-docked: %s\n", is_docked ? "yes" : "no"); g_free (daemon_version); } |