add per type API defines

This commit is contained in:
Wim Taymans 2024-11-21 11:50:12 +01:00
parent b03f2f7afa
commit 31802d4994
85 changed files with 1137 additions and 509 deletions

View file

@ -11,6 +11,14 @@ extern "C" {
#include <spa/support/loop.h>
#ifndef SPA_API_DBUS
#ifdef SPA_API_IMPL
#define SPA_API_DBUS SPA_API_IMPL
#else
#define SPA_API_DBUS static inline
#endif
#endif
/** \defgroup spa_dbus DBus
* DBus communication
*/
@ -81,19 +89,19 @@ struct spa_dbus_connection {
/** \copydoc spa_dbus_connection.get
* \sa spa_dbus_connection.get */
SPA_API_IMPL void *spa_dbus_connection_get(struct spa_dbus_connection *conn)
SPA_API_DBUS void *spa_dbus_connection_get(struct spa_dbus_connection *conn)
{
return spa_api_func_r(void *, NULL, conn, get, 0);
}
/** \copydoc spa_dbus_connection.destroy
* \sa spa_dbus_connection.destroy */
SPA_API_IMPL void spa_dbus_connection_destroy(struct spa_dbus_connection *conn)
SPA_API_DBUS void spa_dbus_connection_destroy(struct spa_dbus_connection *conn)
{
spa_api_func_v(conn, destroy, 0);
}
/** \copydoc spa_dbus_connection.add_listener
* \sa spa_dbus_connection.add_listener */
SPA_API_IMPL void spa_dbus_connection_add_listener(struct spa_dbus_connection *conn,
SPA_API_DBUS void spa_dbus_connection_add_listener(struct spa_dbus_connection *conn,
struct spa_hook *listener,
const struct spa_dbus_connection_events *events,
void *data)
@ -124,7 +132,7 @@ struct spa_dbus_methods {
/** \copydoc spa_dbus_methods.get_connection
* \sa spa_dbus_methods.get_connection
*/
SPA_API_IMPL struct spa_dbus_connection *
SPA_API_DBUS struct spa_dbus_connection *
spa_dbus_get_connection(struct spa_dbus *dbus, enum spa_dbus_type type)
{
return spa_api_method_r(struct spa_dbus_connection *, NULL,