mirror of https://github.com/mpv-player/mpv
command: minor m_property_strdup_ro style changes
This commit is contained in:
parent
2cb1485492
commit
02c6165d2b
|
@ -1781,8 +1781,7 @@ static int mp_property_audio_devices(void *ctx, struct m_property *prop,
|
||||||
static int mp_property_ao(void *ctx, struct m_property *p, int action, void *arg)
|
static int mp_property_ao(void *ctx, struct m_property *p, int action, void *arg)
|
||||||
{
|
{
|
||||||
MPContext *mpctx = ctx;
|
MPContext *mpctx = ctx;
|
||||||
return m_property_strdup_ro(action, arg,
|
return m_property_strdup_ro(action, arg, mpctx->ao ? ao_get_name(mpctx->ao) : NULL);
|
||||||
mpctx->ao ? ao_get_name(mpctx->ao) : NULL);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Audio delay (RW)
|
/// Audio delay (RW)
|
||||||
|
@ -2762,15 +2761,15 @@ static int mp_property_perf_info(void *ctx, struct m_property *p, int action,
|
||||||
static int mp_property_vo(void *ctx, struct m_property *p, int action, void *arg)
|
static int mp_property_vo(void *ctx, struct m_property *p, int action, void *arg)
|
||||||
{
|
{
|
||||||
MPContext *mpctx = ctx;
|
MPContext *mpctx = ctx;
|
||||||
return m_property_strdup_ro(action, arg,
|
return m_property_strdup_ro(action, arg, mpctx->video_out ?
|
||||||
mpctx->video_out ? mpctx->video_out->driver->name : NULL);
|
mpctx->video_out->driver->name : NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int mp_property_gpu_context(void *ctx, struct m_property *p, int action, void *arg)
|
static int mp_property_gpu_context(void *ctx, struct m_property *p, int action, void *arg)
|
||||||
{
|
{
|
||||||
MPContext *mpctx = ctx;
|
MPContext *mpctx = ctx;
|
||||||
return m_property_strdup_ro(action, arg,
|
return m_property_strdup_ro(action, arg, mpctx->video_out ?
|
||||||
mpctx->video_out ? mpctx->video_out->context_name : NULL);
|
mpctx->video_out->context_name : NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int mp_property_osd_dim(void *ctx, struct m_property *prop,
|
static int mp_property_osd_dim(void *ctx, struct m_property *prop,
|
||||||
|
|
Loading…
Reference in New Issue