[gdm/gnome-3-22] daemon: update X11DisplayName on register display



commit e40d6a8cea3a788b17c1d0a44da3472a2a82065d
Author: Mathias Reck <mathias reck teamviewer com>
Date:   Thu Nov 10 16:15:53 2016 +0100

    daemon: update X11DisplayName on register display
    
    When a display registered, the sessions 'display-name' was already updated.
    The displays 'x11-display-name' however was not, so I've just added that.
    Of course that also meant that the 'x11-display-name' could no longer be
    constructor only.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=752341

 daemon/gdm-display.c |    2 +-
 daemon/gdm-manager.c |    4 +++-
 2 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/daemon/gdm-display.c b/daemon/gdm-display.c
index ab84ba4..a7db6f1 100644
--- a/daemon/gdm-display.c
+++ b/daemon/gdm-display.c
@@ -1187,7 +1187,7 @@ gdm_display_class_init (GdmDisplayClass *klass)
                                                               "x11-display-name",
                                                               "x11-display-name",
                                                               NULL,
-                                                              G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+                                                              G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
         g_object_class_install_property (object_class,
                                          PROP_SEAT_ID,
                                          g_param_spec_string ("seat-id",
diff --git a/daemon/gdm-manager.c b/daemon/gdm-manager.c
index eea8704..0056079 100644
--- a/daemon/gdm-manager.c
+++ b/daemon/gdm-manager.c
@@ -781,8 +781,10 @@ gdm_manager_handle_register_display (GdmDBusManager        *manager,
         if (session != NULL) {
                 GPid pid;
 
-                if (x11_display_name != NULL)
+                if (x11_display_name != NULL) {
                         g_object_set (G_OBJECT (session), "display-name", x11_display_name, NULL);
+                        g_object_set (G_OBJECT (display), "x11-display-name", x11_display_name, NULL);
+                }
 
                 /* FIXME: this should happen in gdm-session.c when the session is opened
                  */


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]