From c00eda8ca0c2d8dc772b8cc8b4bdc93ab353dc29 Mon Sep 17 00:00:00 2001 From: Bastien Nocera Date: Thu, 17 Oct 2013 00:46:01 +0200 Subject: tools: Print the display device when using -d --- tools/up-tool.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'tools') diff --git a/tools/up-tool.c b/tools/up-tool.c index e9e6ab4..c77d627 100644 --- a/tools/up-tool.c +++ b/tools/up-tool.c @@ -320,6 +320,16 @@ main (int argc, char **argv) } } g_ptr_array_unref (devices); + device = up_client_get_display_device (client); + if (opt_enumerate) { + g_print ("%s\n", up_device_get_object_path (device)); + } else { + g_print ("Device: %s\n", up_device_get_object_path (device)); + text = up_device_to_text (device); + g_print ("%s\n", text); + g_free (text); + } + g_object_unref (device); if (opt_dump) { g_print ("Daemon:\n"); up_client_print (client); -- cgit v1.2.1