X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=atk-adaptor%2Fbridge.c;h=1374b99ec078e016d7937ae610dfdb49ed1474bc;hb=d135882cc3d595c5fc2f467a0b243753b57d956a;hp=7e72ec511cc23a4a35e1250c6256e76a8e82abe8;hpb=4a7e2b12ebfa8d366df9ae368a331066741c81d4;p=platform%2Fcore%2Fuifw%2Fat-spi2-atk.git diff --git a/atk-adaptor/bridge.c b/atk-adaptor/bridge.c index 7e72ec5..1374b99 100644 --- a/atk-adaptor/bridge.c +++ b/atk-adaptor/bridge.c @@ -195,10 +195,8 @@ spi_app_init (AtkObject *root) return NULL; } //dbus_connection_set_exit_on_disconnect(ad->droute.bus, FALSE); - //dbus_bus_register(ad->droute.bus, &error); + dbus_bus_register(ad->droute.bus, &error); spi_dbus_initialize (&ad->droute); - /* Below line for testing -- it should be removed once at-spi-registryd is working */ - if (dbus_bus_request_name(ad->droute.bus, "test.atspi.tree", 0, &error)) printf("Got test name.\n"); spi_register_tree_object(ad->droute.bus, &ad->droute, "/org/freedesktop/atspi/tree"); if (!dbus_connection_try_register_fallback (ad->droute.bus, "/org/freedesktop/atspi/accessible", &droute_vtable, &ad->droute, &error)) { @@ -342,8 +340,16 @@ spi_atk_bridge_toplevel_removed (AtkObject *object, static void spi_atk_bridge_register_application (const char *registry) { + DBusMessage *message, *reply; + DBusError error; + bridge_threads_leave (); - // TODO: register + message = dbus_message_new_method_call (SPI_DBUS_NAME_REGISTRY, SPI_DBUS_PATH_REGISTRY, SPI_DBUS_INTERFACE_REGISTRY, "registerApplication"); + dbus_error_init (&error); + reply = dbus_connection_send_with_reply_and_block(this_app->droute.bus, message, 1000, &error); + if (error.message) g_warning (error.message); + if (reply) dbus_message_unref (reply); + if (message) dbus_message_unref (message); bridge_threads_enter (); }