[gdm/wip/slave-connection: 27/32] daemon: drop display-id arg to session constructor
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gdm/wip/slave-connection: 27/32] daemon: drop display-id arg to session constructor
- Date: Tue, 10 Jul 2012 06:25:18 +0000 (UTC)
commit ffb4325ca198d7502c168c1affcc5aa391e0c4be
Author: Ray Strode <rstrode redhat com>
Date: Mon Jul 9 21:17:25 2012 -0400
daemon: drop display-id arg to session constructor
It's not used anywhere, and so there's no reason to pass it along.
daemon/gdm-session.c | 30 +-----------------------------
daemon/gdm-session.h | 3 +--
daemon/gdm-simple-slave.c | 3 +--
daemon/gdm-welcome-session.c | 3 +--
daemon/test-session.c | 3 +--
5 files changed, 5 insertions(+), 37 deletions(-)
---
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
index 4f3e9bb..af28e8d 100644
--- a/daemon/gdm-session.c
+++ b/daemon/gdm-session.c
@@ -100,7 +100,6 @@ struct _GdmSessionPrivate
GPid session_pid;
/* object lifetime scope */
- char *display_id;
char *display_name;
char *display_hostname;
char *display_device;
@@ -117,7 +116,6 @@ struct _GdmSessionPrivate
enum {
PROP_0,
- PROP_DISPLAY_ID,
PROP_DISPLAY_NAME,
PROP_DISPLAY_HOSTNAME,
PROP_DISPLAY_IS_LOCAL,
@@ -2633,14 +2631,6 @@ gdm_session_select_language (GdmSession *self,
}
}
-static void
-set_display_id (GdmSession *self,
- const char *id)
-{
- g_free (self->priv->display_id);
- self->priv->display_id = g_strdup (id);
-}
-
/* At some point we may want to read these right from
* the slave but for now I don't want the dependency */
static void
@@ -2710,9 +2700,6 @@ gdm_session_set_property (GObject *object,
self = GDM_SESSION (object);
switch (prop_id) {
- case PROP_DISPLAY_ID:
- set_display_id (self, g_value_get_string (value));
- break;
case PROP_DISPLAY_NAME:
set_display_name (self, g_value_get_string (value));
break;
@@ -2751,9 +2738,6 @@ gdm_session_get_property (GObject *object,
self = GDM_SESSION (object);
switch (prop_id) {
- case PROP_DISPLAY_ID:
- g_value_set_string (value, self->priv->display_id);
- break;
case PROP_DISPLAY_NAME:
g_value_set_string (value, self->priv->display_name);
break;
@@ -2792,9 +2776,6 @@ gdm_session_dispose (GObject *object)
gdm_session_close (self);
- g_free (self->priv->display_id);
- self->priv->display_id = NULL;
-
g_free (self->priv->display_name);
self->priv->display_name = NULL;
@@ -3018,13 +2999,6 @@ gdm_session_class_init (GdmSessionClass *session_class)
0);
g_object_class_install_property (object_class,
- PROP_DISPLAY_ID,
- g_param_spec_string ("display-id",
- "display id",
- "display id",
- NULL,
- G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
- g_object_class_install_property (object_class,
PROP_DISPLAY_NAME,
g_param_spec_string ("display-name",
"display name",
@@ -3078,8 +3052,7 @@ gdm_session_class_init (GdmSessionClass *session_class)
}
GdmSession *
-gdm_session_new (const char *display_id,
- const char *display_name,
+gdm_session_new (const char *display_name,
const char *display_hostname,
const char *display_device,
const char *display_seat_id,
@@ -3089,7 +3062,6 @@ gdm_session_new (const char *display_id,
GdmSession *self;
self = g_object_new (GDM_TYPE_SESSION,
- "display-id", display_id,
"display-name", display_name,
"display-hostname", display_hostname,
"display-device", display_device,
diff --git a/daemon/gdm-session.h b/daemon/gdm-session.h
index 5b23019..22e8c35 100644
--- a/daemon/gdm-session.h
+++ b/daemon/gdm-session.h
@@ -77,8 +77,7 @@ typedef struct
GType gdm_session_get_type (void);
-GdmSession *gdm_session_new (const char *display_id,
- const char *display_name,
+GdmSession *gdm_session_new (const char *display_name,
const char *display_hostname,
const char *display_device,
const char *display_seat_id,
diff --git a/daemon/gdm-simple-slave.c b/daemon/gdm-simple-slave.c
index 5aef8bb..9668ac5 100644
--- a/daemon/gdm-simple-slave.c
+++ b/daemon/gdm-simple-slave.c
@@ -612,8 +612,7 @@ create_new_session (GdmSimpleSlave *slave)
display_device = gdm_server_get_display_device (slave->priv->server);
}
- slave->priv->session = gdm_session_new (display_id,
- display_name,
+ slave->priv->session = gdm_session_new (display_name,
display_hostname,
display_device,
display_seat_id,
diff --git a/daemon/gdm-welcome-session.c b/daemon/gdm-welcome-session.c
index ad25639..e488409 100644
--- a/daemon/gdm-welcome-session.c
+++ b/daemon/gdm-welcome-session.c
@@ -787,8 +787,7 @@ gdm_welcome_session_start (GdmWelcomeSession *welcome_session)
return FALSE;
}
- welcome_session->priv->session = gdm_session_new (NULL,
- welcome_session->priv->x11_display_name,
+ welcome_session->priv->session = gdm_session_new (welcome_session->priv->x11_display_name,
welcome_session->priv->x11_display_hostname,
welcome_session->priv->x11_display_device,
welcome_session->priv->x11_display_seat_id,
diff --git a/daemon/test-session.c b/daemon/test-session.c
index 85e13d8..b907bb1 100644
--- a/daemon/test-session.c
+++ b/daemon/test-session.c
@@ -247,8 +247,7 @@ main (int argc,
do {
g_debug ("creating instance of GdmSession object...");
- session = gdm_session_new ("/org/gnome/DisplayManager/Displays/_0",
- ":0",
+ session = gdm_session_new (":0",
g_get_host_name (),
ttyname (STDIN_FILENO),
"",
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]