Cleanup argument names in methods and events interfaces

First method argument is object, first event argument is data.

Closes !963
This commit is contained in:
Quentin Wenger 2021-09-27 15:09:32 +02:00 committed by Wim Taymans
parent d3ea3142e1
commit 22fc9eec35
55 changed files with 636 additions and 636 deletions

View file

@ -259,10 +259,10 @@ static struct mix *ensure_mix(struct node_data *data,
}
static int client_node_transport(void *object,
static int client_node_transport(void *_data,
int readfd, int writefd, uint32_t mem_id, uint32_t offset, uint32_t size)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
clean_transport(data);
@ -416,10 +416,10 @@ static int add_port_update(struct node_data *data, struct pw_impl_port *port, ui
}
static int
client_node_set_param(void *object, uint32_t id, uint32_t flags,
client_node_set_param(void *_data, uint32_t id, uint32_t flags,
const struct spa_pod *param)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
int res;
@ -440,13 +440,13 @@ client_node_set_param(void *object, uint32_t id, uint32_t flags,
}
static int
client_node_set_io(void *object,
client_node_set_io(void *_data,
uint32_t id,
uint32_t memid,
uint32_t offset,
uint32_t size)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
struct pw_memmap *old, *mm;
void *ptr;
@ -483,15 +483,15 @@ exit:
return res;
}
static int client_node_event(void *object, const struct spa_event *event)
static int client_node_event(void *data, const struct spa_event *event)
{
pw_log_warn("unhandled node event %d", SPA_EVENT_TYPE(event));
return -ENOTSUP;
}
static int client_node_command(void *object, const struct spa_command *command)
static int client_node_command(void *_data, const struct spa_command *command)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
int res;
@ -533,10 +533,10 @@ static int client_node_command(void *object, const struct spa_command *command)
}
static int
client_node_add_port(void *object, enum spa_direction direction, uint32_t port_id,
client_node_add_port(void *_data, enum spa_direction direction, uint32_t port_id,
const struct spa_dict *props)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
pw_log_warn("add port not supported");
pw_proxy_error(proxy, -ENOTSUP, "add port not supported");
@ -544,9 +544,9 @@ client_node_add_port(void *object, enum spa_direction direction, uint32_t port_i
}
static int
client_node_remove_port(void *object, enum spa_direction direction, uint32_t port_id)
client_node_remove_port(void *_data, enum spa_direction direction, uint32_t port_id)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
pw_log_warn("remove port not supported");
pw_proxy_error(proxy, -ENOTSUP, "remove port not supported");
@ -579,12 +579,12 @@ static int clear_buffers(struct node_data *data, struct mix *mix)
}
static int
client_node_port_set_param(void *object,
client_node_port_set_param(void *_data,
enum spa_direction direction, uint32_t port_id,
uint32_t id, uint32_t flags,
const struct spa_pod *param)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
struct pw_impl_port *port;
int res;
@ -620,12 +620,12 @@ error_exit:
}
static int
client_node_port_use_buffers(void *object,
client_node_port_use_buffers(void *_data,
enum spa_direction direction, uint32_t port_id, uint32_t mix_id,
uint32_t flags,
uint32_t n_buffers, struct pw_client_node_buffer *buffers)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
struct buffer *bid;
uint32_t i, j;
@ -769,7 +769,7 @@ error_exit:
}
static int
client_node_port_set_io(void *object,
client_node_port_set_io(void *_data,
uint32_t direction,
uint32_t port_id,
uint32_t mix_id,
@ -778,7 +778,7 @@ client_node_port_set_io(void *object,
uint32_t offset,
uint32_t size)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
struct mix *mix;
struct pw_memmap *mm, *old;
@ -869,14 +869,14 @@ do_activate_link(struct spa_loop *loop,
}
static int
client_node_set_activation(void *object,
client_node_set_activation(void *_data,
uint32_t node_id,
int signalfd,
uint32_t memid,
uint32_t offset,
uint32_t size)
{
struct node_data *data = object;
struct node_data *data = _data;
struct pw_proxy *proxy = (struct pw_proxy*)data->client_node;
struct pw_impl_node *node = data->node;
struct pw_memmap *mm;