From 9f80936ddc05b27945637b7944b8b6c894ff87ac Mon Sep 17 00:00:00 2001 From: wm4 Date: Wed, 10 Dec 2014 17:52:21 +0100 Subject: player: update chapter marks when switching files This wasn't done, so the chapter marks of the previous file were visible. It's harmless, but looks unpolished, so fix it. Conflicts: player/command.c --- player/command.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'player') diff --git a/player/command.c b/player/command.c index 30189c72a5..9bd3b21deb 100644 --- a/player/command.c +++ b/player/command.c @@ -4627,8 +4627,11 @@ static void command_event(struct MPContext *mpctx, int event, void *arg) } ctx->prev_pts = now; } - if (event == MPV_EVENT_SEEK) { + if (event == MPV_EVENT_SEEK) ctx->prev_pts = MP_NOPTS_VALUE; + if (event == MPV_EVENT_END_FILE || event == MPV_EVENT_FILE_LOADED) { + // Update chapters - does nothing if something else is visible. + set_osd_bar_chapters(mpctx, OSD_BAR_SEEK); } } -- cgit v1.2.3