diff --git a/src/pipewire/global.c b/src/pipewire/global.c index 2247ce193..43403e91b 100644 --- a/src/pipewire/global.c +++ b/src/pipewire/global.c @@ -211,6 +211,16 @@ const struct pw_properties *pw_global_get_properties(struct pw_global *global) return global->properties; } +SPA_EXPORT +int pw_global_update_keys(struct pw_global *global, + const struct spa_dict *dict, const char *keys[]) +{ + struct impl *impl = SPA_CONTAINER_OF(global, struct impl, this); + if (impl->registered) + return -EINVAL; + return pw_properties_update_keys(global->properties, dict, keys); +} + SPA_EXPORT void * pw_global_get_object(struct pw_global *global) { diff --git a/src/pipewire/global.h b/src/pipewire/global.h index 399a8d4cc..d0edad7bb 100644 --- a/src/pipewire/global.h +++ b/src/pipewire/global.h @@ -113,6 +113,10 @@ uint32_t pw_global_get_version(struct pw_global *global); /** Get the global properties */ const struct pw_properties *pw_global_get_properties(struct pw_global *global); +/** Update the global properties, must be done when unregistered */ +int pw_global_update_keys(struct pw_global *global, + const struct spa_dict *dict, const char *keys[]); + /** Get the object associated with the global. This depends on the type of the * global */ void *pw_global_get_object(struct pw_global *global);