summaryrefslogtreecommitdiffstats
path: root/player
diff options
context:
space:
mode:
authorDudemanguy <random342@airmail.cc>2023-09-19 20:54:40 -0500
committerDudemanguy <random342@airmail.cc>2023-09-21 16:06:29 +0000
commit4b2276b730c8542649b665aaec187e1c7e3b2612 (patch)
tree3cc59b916f1223b308a867ed9595dd2fc24d7ee1 /player
parent29b481da54f3779b70381ae3ff79bea0b39d110f (diff)
downloadmpv-4b2276b730c8542649b665aaec187e1c7e3b2612.tar.bz2
mpv-4b2276b730c8542649b665aaec187e1c7e3b2612.tar.xz
command: stop restarting playback when writing to playlist-pos
e9e93b4dbe748cd341a6fbea355e6ba013ada81b added a warning about writing the same value to the playlist-pos property that in the future it would stop restarting playback. Instead, you should use the playlist-play-index command for that. Well go ahead and drop the old deprecated behavior now and do what wm4 wanted this to do: just ignore if the same value is written again.
Diffstat (limited to 'player')
-rw-r--r--player/command.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/player/command.c b/player/command.c
index 0511b1cef5..57341dc39d 100644
--- a/player/command.c
+++ b/player/command.c
@@ -3037,11 +3037,8 @@ static int mp_property_playlist_pos_x(void *ctx, struct m_property *prop,
}
case M_PROPERTY_SET: {
int pos = *(int *)arg - base;
- if (pos >= 0 && playlist_entry_to_index(pl, pl->current) == pos) {
- MP_WARN(mpctx, "Behavior of %s when writing the same value will "
- "change (currently restarts, it will stop doing this).\n",
- prop->name);
- }
+ if (pos >= 0 && playlist_entry_to_index(pl, pl->current) == pos)
+ return M_PROPERTY_OK;
mp_set_playlist_entry(mpctx, playlist_entry_from_index(pl, pos));
return M_PROPERTY_OK;
}