mirror of
https://gitlab.freedesktop.org/pipewire/wireplumber.git
synced 2026-05-07 11:08:04 +02:00
m-metadata: add callback for wp_object_activate()
A callback is required, NULL is not accepted by GCClosure
This commit is contained in:
parent
a7dcd3b76f
commit
58310c73aa
1 changed files with 11 additions and 1 deletions
|
|
@ -24,6 +24,16 @@ wp_metadata_plugin_init (WpMetadataPlugin * self)
|
|||
{
|
||||
}
|
||||
|
||||
static void
|
||||
on_metadata_activated (GObject * obj, GAsyncResult * res, gpointer user_data)
|
||||
{
|
||||
g_autoptr (GError) error = NULL;
|
||||
if (!wp_object_activate_finish (WP_OBJECT (obj), res, &error)) {
|
||||
wp_warning_object (user_data, "failed to activate WpImplMetadata: %s",
|
||||
error->message);
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
wp_metadata_plugin_activate (WpPlugin * plugin)
|
||||
{
|
||||
|
|
@ -33,7 +43,7 @@ wp_metadata_plugin_activate (WpPlugin * plugin)
|
|||
|
||||
self->metadata = wp_impl_metadata_new (core);
|
||||
wp_object_activate (WP_OBJECT (self->metadata),
|
||||
WP_OBJECT_FEATURES_ALL, NULL, NULL, self);
|
||||
WP_OBJECT_FEATURES_ALL, NULL, on_metadata_activated, self);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue