Permalink
Browse files

Computer/Display: Add X Display Name

A field exists in struct _DisplayInfo, but it wasn't being
filled or shown.

Perhaps fix:
#181

Signed-off-by: Burt P <pburt0@gmail.com>
  • Loading branch information...
bp0 authored and lpereira committed Oct 28, 2017
1 parent 9114299 commit 34ebc7e5d99c9d41a28b842cca433041bb92f9d2
Showing with 5 additions and 2 deletions.
  1. +1 −0 modules/computer.c
  2. +4 −2 modules/computer/display.c
View
@@ -582,6 +582,7 @@ gchar *callback_display(void)
computer->display->width, computer->display->height),
info_field(_("Vendor"), computer->display->vendor),
info_field(_("Version"), computer->display->version),
info_field(_("Current Display Name"), computer->display->display_name),
info_field_last());
info_add_computed_group(info, _("Monitors"), computer->display->monitors);
@@ -75,15 +75,17 @@ get_x11_info(DisplayInfo *di)
g_free(output);
old = output_lines;
while (*(output_lines++)) {
gchar **tmp = g_strsplit(*output_lines, ":", 0);
while (*output_lines) {
gchar **tmp = g_strsplit(*output_lines, ":", 2);
output_lines++;
if (tmp[1] && tmp[0]) {
tmp[1] = g_strchug(tmp[1]);
get_str("vendor string", di->vendor);
get_str("X.Org version", di->version);
get_str("XFree86 version", di->version);
get_str("name of display", di->display_name);
if (g_str_has_prefix(tmp[0], "number of extensions")) {
int n;

0 comments on commit 34ebc7e

Please sign in to comment.