Make Tilda work without DBus
[tilda-gobject.git] / tilda-controller.c
index a3d6f67..4127920 100644 (file)
@@ -15,6 +15,10 @@ tilda_controller_dbus_register_object (TildaController *self)
 
        static const gchar object_path[] = "/net/sourceforge/Tilda";
 
+       /* If DBus is not running, leave */
+       if (!dbus_connection)
+               return;
+
        dbus_g_connection_register_g_object (dbus_connection, object_path, G_OBJECT(self));
 }
 
@@ -240,7 +244,6 @@ tilda_controller_constructor (GType                  type,
        obj = parent_class->constructor (type,
                                                                         n_construct_properties,
                                                                         construct_properties);
-       g_print ("%s all set up\n", __func__);
 
        /* The object is ready, and all constructor-time properties have been set.
         * Have fun! */