diff options
author | Xavier Claessens <xclaesse@src.gnome.org> | 2008-02-26 21:31:16 +0800 |
---|---|---|
committer | Xavier Claessens <xclaesse@src.gnome.org> | 2008-02-26 21:31:16 +0800 |
commit | c524708b1e398a1f81ce430f765ef825ca780f37 (patch) | |
tree | 466e29fca7fb12078f7a727b7d50ac7487a618fc | |
parent | 389d71af383dacd5e67d460811926b34d7fcf22f (diff) | |
download | gsoc2013-empathy-c524708b1e398a1f81ce430f765ef825ca780f37.tar.gz gsoc2013-empathy-c524708b1e398a1f81ce430f765ef825ca780f37.tar.zst gsoc2013-empathy-c524708b1e398a1f81ce430f765ef825ca780f37.zip |
It's now safe to call emp_cli_init multiple times. Move that call to empathy_tp_call_class_init.
svn path=/trunk/; revision=665
-rw-r--r-- | extensions/extensions-cli.c | 12 | ||||
-rw-r--r-- | libempathy/empathy-tp-call.c | 2 | ||||
-rw-r--r-- | src/empathy-call-chandler.c | 2 |
3 files changed, 11 insertions, 5 deletions
diff --git a/extensions/extensions-cli.c b/extensions/extensions-cli.c index 98a174478..c75633c33 100644 --- a/extensions/extensions-cli.c +++ b/extensions/extensions-cli.c @@ -12,8 +12,14 @@ static void _emp_ext_register_dbus_glib_marshallers (void); void emp_cli_init (void) { - _emp_ext_register_dbus_glib_marshallers (); + static gboolean initilized = FALSE; - tp_proxy_or_subclass_hook_on_interface_add (TP_TYPE_PROXY, - emp_cli_misc_add_signals); + if (!initialized) + { + _emp_ext_register_dbus_glib_marshallers (); + + tp_proxy_or_subclass_hook_on_interface_add (TP_TYPE_PROXY, + emp_cli_misc_add_signals); + initialized = TRUE; + } } diff --git a/libempathy/empathy-tp-call.c b/libempathy/empathy-tp-call.c index 6dd24a51a..c44ffe27e 100644 --- a/libempathy/empathy-tp-call.c +++ b/libempathy/empathy-tp-call.c @@ -678,6 +678,8 @@ empathy_tp_call_class_init (EmpathyTpCallClass *klass) { GObjectClass *object_class = G_OBJECT_CLASS (klass); + emp_cli_init (); + object_class->constructor = tp_call_constructor; object_class->finalize = tp_call_finalize; object_class->set_property = tp_call_set_property; diff --git a/src/empathy-call-chandler.c b/src/empathy-call-chandler.c index 2b359ec24..e1568c18c 100644 --- a/src/empathy-call-chandler.c +++ b/src/empathy-call-chandler.c @@ -22,7 +22,6 @@ #include <libmissioncontrol/mission-control.h> -#include <extensions/extensions.h> #include <libempathy/empathy-tp-call.h> #include <libempathy/empathy-chandler.h> #include <libempathy/empathy-debug.h> @@ -69,7 +68,6 @@ main (int argc, char *argv[]) EmpathyChandler *chandler; gtk_init (&argc, &argv); - emp_cli_init (); mc = empathy_mission_control_new (); |