client API: move a function

May reduce the diff of the next commit.
This commit is contained in:
wm4 2019-10-24 16:48:32 +02:00
parent 436bf04d5f
commit 922be71101
1 changed files with 7 additions and 7 deletions

View File

@ -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)
{