summaryrefslogtreecommitdiff
path: root/src/seat.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/seat.c')
-rw-r--r--src/seat.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/seat.c b/src/seat.c
index 14617425..7d68dda9 100644
--- a/src/seat.c
+++ b/src/seat.c
@@ -114,9 +114,8 @@ seat_register_module (const gchar *name, GType type)
}
Seat *
-seat_new (const gchar *module_name, const gchar *name)
+seat_new (const gchar *module_name)
{
- Seat *seat;
SeatModule *m = NULL;
g_return_val_if_fail (module_name != NULL, NULL);
@@ -126,10 +125,15 @@ seat_new (const gchar *module_name, const gchar *name)
if (!m)
return NULL;
- seat = g_object_new (m->type, NULL);
- seat->priv->name = g_strdup (name);
+ return g_object_new (m->type, NULL);
+}
- return seat;
+void
+seat_set_name (Seat *seat, const gchar *name)
+{
+ g_return_if_fail (seat != NULL);
+ g_free (seat->priv->name);
+ seat->priv->name = g_strdup (name);
}
void