mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-09 12:25:48 +01:00
GDBusObjectManagerClient: Emit signals on proxy before emitting on manager
This is needed because the proxy may need to update its internal state which a signal handler connected to the manager may rely on. Signed-off-by: David Zeuthen <davidz@redhat.com>
This commit is contained in:
parent
230efe70f4
commit
20a4f2578f
@ -1021,6 +1021,10 @@ signal_cb (GDBusConnection *connection,
|
|||||||
NULL);
|
NULL);
|
||||||
}
|
}
|
||||||
/* ... and then synthesize the signal */
|
/* ... and then synthesize the signal */
|
||||||
|
g_signal_emit_by_name (interface,
|
||||||
|
"g-properties-changed",
|
||||||
|
changed_properties,
|
||||||
|
invalidated_properties);
|
||||||
g_signal_emit (manager,
|
g_signal_emit (manager,
|
||||||
signals[INTERFACE_PROXY_PROPERTIES_CHANGED_SIGNAL],
|
signals[INTERFACE_PROXY_PROPERTIES_CHANGED_SIGNAL],
|
||||||
0,
|
0,
|
||||||
@ -1028,10 +1032,6 @@ signal_cb (GDBusConnection *connection,
|
|||||||
interface,
|
interface,
|
||||||
changed_properties,
|
changed_properties,
|
||||||
invalidated_properties);
|
invalidated_properties);
|
||||||
g_signal_emit_by_name (interface,
|
|
||||||
"g-properties-changed",
|
|
||||||
changed_properties,
|
|
||||||
invalidated_properties);
|
|
||||||
g_object_unref (interface);
|
g_object_unref (interface);
|
||||||
}
|
}
|
||||||
g_variant_unref (changed_properties);
|
g_variant_unref (changed_properties);
|
||||||
@ -1044,6 +1044,11 @@ signal_cb (GDBusConnection *connection,
|
|||||||
interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object_proxy), interface_name);
|
interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object_proxy), interface_name);
|
||||||
if (interface != NULL)
|
if (interface != NULL)
|
||||||
{
|
{
|
||||||
|
g_signal_emit_by_name (interface,
|
||||||
|
"g-signal",
|
||||||
|
sender_name,
|
||||||
|
signal_name,
|
||||||
|
parameters);
|
||||||
g_signal_emit (manager,
|
g_signal_emit (manager,
|
||||||
signals[INTERFACE_PROXY_SIGNAL_SIGNAL],
|
signals[INTERFACE_PROXY_SIGNAL_SIGNAL],
|
||||||
0,
|
0,
|
||||||
@ -1052,11 +1057,6 @@ signal_cb (GDBusConnection *connection,
|
|||||||
sender_name,
|
sender_name,
|
||||||
signal_name,
|
signal_name,
|
||||||
parameters);
|
parameters);
|
||||||
g_signal_emit_by_name (interface,
|
|
||||||
"g-signal",
|
|
||||||
sender_name,
|
|
||||||
signal_name,
|
|
||||||
parameters);
|
|
||||||
g_object_unref (interface);
|
g_object_unref (interface);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user