mirror of
https://github.com/mpv-player/mpv
synced 2025-01-13 18:45:25 +00:00
client API: move a function
May reduce the diff of the next commit.
This commit is contained in:
parent
436bf04d5f
commit
922be71101
@ -1454,6 +1454,13 @@ int mpv_observe_property(mpv_handle *ctx, uint64_t userdata,
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void mark_property_changed(struct mpv_handle *client, int index)
|
||||
{
|
||||
struct observe_property *prop = client->properties[index];
|
||||
prop->changed = true;
|
||||
client->lowest_changed = MPMIN(client->lowest_changed, index);
|
||||
}
|
||||
|
||||
int mpv_unobserve_property(mpv_handle *ctx, uint64_t userdata)
|
||||
{
|
||||
pthread_mutex_lock(&ctx->lock);
|
||||
@ -1482,13 +1489,6 @@ int mpv_unobserve_property(mpv_handle *ctx, uint64_t userdata)
|
||||
return count;
|
||||
}
|
||||
|
||||
static void mark_property_changed(struct mpv_handle *client, int index)
|
||||
{
|
||||
struct observe_property *prop = client->properties[index];
|
||||
prop->changed = true;
|
||||
client->lowest_changed = MPMIN(client->lowest_changed, index);
|
||||
}
|
||||
|
||||
// Broadcast that a property has changed.
|
||||
void mp_client_property_change(struct MPContext *mpctx, const char *name)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user