From f60826c3a14ba3b49077f17e5364b7347f9b468a Mon Sep 17 00:00:00 2001 From: wm4 Date: Fri, 23 Mar 2018 16:24:49 +0100 Subject: client API: add a first class hook API, and deprecate old API As it turns out, there are multiple libmpv users who saw a need to use the hook API. The API is kind of shitty and was never meant to be actually public (it was mostly a hack for the ytdl script). Introduce a proper API and deprecate the old one. The old one will probably continue to work for a few releases, but will be removed eventually. There are some slight changes to the old API, but if a user followed the manual properly, it won't break. Mostly untested. Appears to work with ytdl_hook. --- player/client.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'player/client.h') diff --git a/player/client.h b/player/client.h index 9ecbe2ed35..b1c2ffc500 100644 --- a/player/client.h +++ b/player/client.h @@ -25,7 +25,7 @@ bool mp_clients_all_initialized(struct MPContext *mpctx); bool mp_client_exists(struct MPContext *mpctx, const char *client_name); void mp_client_broadcast_event(struct MPContext *mpctx, int event, void *data); int mp_client_send_event(struct MPContext *mpctx, const char *client_name, - int event, void *data); + uint64_t reply_userdata, int event, void *data); int mp_client_send_event_dup(struct MPContext *mpctx, const char *client_name, int event, void *data); bool mp_client_event_is_registered(struct MPContext *mpctx, int event); -- cgit v1.2.3