[gdm/wip/slave-display-merger: 28/30] display: add start_server vfunc
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gdm/wip/slave-display-merger: 28/30] display: add start_server vfunc
- Date: Wed, 11 Feb 2015 21:43:11 +0000 (UTC)
commit ad6dc699d745677dea5d0da71db2e3391c85d0d3
Author: Ray Strode <rstrode redhat com>
Date: Wed Feb 4 10:28:38 2015 -0500
display: add start_server vfunc
This function will be overridden by GdmLocalDisplay to
start the X server.
daemon/gdm-display.c | 15 ++++++++++++++-
daemon/gdm-display.h | 3 ++-
2 files changed, 16 insertions(+), 2 deletions(-)
---
diff --git a/daemon/gdm-display.c b/daemon/gdm-display.c
index e1b3841..7ee9ff4 100644
--- a/daemon/gdm-display.c
+++ b/daemon/gdm-display.c
@@ -625,6 +625,12 @@ on_slave_started (GdmSlave *slave,
_gdm_display_set_status (self, GDM_DISPLAY_MANAGED);
}
+static void
+gdm_display_real_start_server (GdmDisplay *self)
+{
+ gdm_slave_start (self->priv->slave);
+}
+
static gboolean
gdm_display_real_prepare (GdmDisplay *self)
{
@@ -655,6 +661,12 @@ gdm_display_real_prepare (GdmDisplay *self)
}
static void
+gdm_display_start_server (GdmDisplay *self)
+{
+ GDM_DISPLAY_GET_CLASS (self)->start_server (self);
+}
+
+static void
on_list_cached_users_complete (GObject *proxy,
GAsyncResult *result,
GdmDisplay *self)
@@ -673,7 +685,7 @@ on_list_cached_users_complete (GObject *proxy,
g_variant_unref (call_result);
}
- gdm_slave_start (self->priv->slave);
+ gdm_display_start_server (self);
}
static void
@@ -1377,6 +1389,7 @@ gdm_display_class_init (GdmDisplayClass *klass)
object_class->finalize = gdm_display_finalize;
klass->prepare = gdm_display_real_prepare;
+ klass->start_server = gdm_display_real_start_server;
g_object_class_install_property (object_class,
PROP_ID,
diff --git a/daemon/gdm-display.h b/daemon/gdm-display.h
index 39976b9..f691979 100644
--- a/daemon/gdm-display.h
+++ b/daemon/gdm-display.h
@@ -56,7 +56,8 @@ typedef struct
GObjectClass parent_class;
/* methods */
- gboolean (*prepare) (GdmDisplay *display);
+ gboolean (*prepare) (GdmDisplay *display);
+ void (* start_server) (GdmDisplay *self);
} GdmDisplayClass;
typedef enum
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]