mirror of
https://github.com/troglobit/finit.git
synced 2026-10-11 17:02:42 +07:00
libink: declare signals in introspection XML
All three org.finit signals were invisible to generated proxies, and org.freedesktop.DBus was missing from the standard interfaces even though Hello, AddMatch, and RemoveMatch are answered. Add a link_signal_t table to the vtable, emitted like methods and properties, declare the Manager1 and Cond1 signals, and complete the static XML with PropertiesChanged and org.freedesktop.DBus. Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
+13
@@ -623,10 +623,17 @@ static const link_method_t manager_methods[] = {
|
||||
{ NULL, NULL, NULL, 0, NULL }
|
||||
};
|
||||
|
||||
static const link_signal_t manager_signals[] = {
|
||||
{ .name = "ServiceStateChanged", .sig = "sss" },
|
||||
{ .name = "RunlevelChanged", .sig = "ss" },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const link_vtable_t manager_vtable = {
|
||||
.interface = "org.finit.Manager1",
|
||||
.methods = manager_methods,
|
||||
.properties = manager_properties,
|
||||
.signals = manager_signals,
|
||||
};
|
||||
|
||||
/* ---------- org.finit.Service1 (one object per service) ----------
|
||||
@@ -1251,9 +1258,15 @@ static const link_method_t cond_methods[] = {
|
||||
{ NULL, NULL, NULL, 0, NULL }
|
||||
};
|
||||
|
||||
static const link_signal_t cond_signals[] = {
|
||||
{ .name = "ConditionChanged", .sig = "ss" },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const link_vtable_t cond_vtable = {
|
||||
.interface = COND_INTERFACE,
|
||||
.methods = cond_methods,
|
||||
.signals = cond_signals,
|
||||
};
|
||||
|
||||
/* ---------- signal emission: ConditionChanged ---------- */
|
||||
|
||||
Reference in New Issue
Block a user