Set correct sender and interface when sending org.freedesktop.IBus signals.
authorDaiki Ueno <ueno@unixuser.org>
Fri, 7 Jan 2011 01:42:44 +0000 (10:42 +0900)
committerDaiki Ueno <ueno@unixuser.org>
Fri, 7 Jan 2011 01:42:44 +0000 (10:42 +0900)
BUG=none
TEST=manual

Review URL: http://codereview.appspot.com/3775042

bus/dbusimpl.c
bus/ibusimpl.c
bus/inputcontext.c

index c8fbc9d..91e995e 100644 (file)
@@ -419,7 +419,7 @@ bus_dbus_impl_get_name_owner (BusDBusImpl           *dbus,
 
     if (g_strcmp0 (name, "org.freedesktop.DBus") == 0 ||
         g_strcmp0 (name, "org.freedesktop.IBus") == 0) {
-        name_owner = "org.freedesktop.DBus";
+        name_owner = name;
     }
     else {
         BusConnection *owner = bus_dbus_impl_get_connection_by_name (dbus, name);
index 63d551b..8a1f799 100644 (file)
@@ -1834,9 +1834,9 @@ bus_ibus_impl_emit_signal (BusIBusImpl *ibus,
 {
 
     GDBusMessage *message = g_dbus_message_new_signal ("/org/freedesktop/IBus",
-                                                       "org.freedesktop.DBus",
+                                                       "org.freedesktop.IBus",
                                                        signal_name);
-    g_dbus_message_set_sender (message, "org.freedesktop.DBus");
+    g_dbus_message_set_sender (message, "org.freedesktop.IBus");
     if (parameters)
         g_dbus_message_set_body (message, parameters);
     bus_dbus_impl_dispatch_message_by_rule (BUS_DEFAULT_DBUS, message, NULL);
index 8952556..32d51e8 100644 (file)
@@ -645,7 +645,7 @@ bus_input_context_emit_signal (BusInputContext *context,
     GDBusMessage *message = g_dbus_message_new_signal (ibus_service_get_object_path ((IBusService *)context),
                                                        "org.freedesktop.IBus.InputContext",
                                                        signal_name);
-    g_dbus_message_set_sender (message, "org.freedesktop.DBus");
+    g_dbus_message_set_sender (message, "org.freedesktop.IBus");
     g_dbus_message_set_destination (message, bus_connection_get_unique_name (context->connection));
     if (parameters != NULL)
         g_dbus_message_set_body (message, parameters);