mirror of
https://github.com/mpv-player/mpv.git
synced 2026-10-29 07:06:59 +08:00
player: reset some VO state when video is terminated
Useful for idle mode or if video is switched off during playback, and --force-window is used.
This commit is contained in:
@@ -810,6 +810,9 @@ void handle_force_window(struct MPContext *mpctx, bool reconfig)
|
|||||||
.d_w = w, .d_h = h,
|
.d_w = w, .d_h = h,
|
||||||
};
|
};
|
||||||
vo_reconfig(vo, &p, 0);
|
vo_reconfig(vo, &p, 0);
|
||||||
|
vo_control(vo, VOCTRL_SET_CURSOR_VISIBILITY, &(bool){true});
|
||||||
|
vo_control(vo, VOCTRL_RESTORE_SCREENSAVER, NULL);
|
||||||
|
vo_set_paused(vo, true);
|
||||||
vo_redraw(vo);
|
vo_redraw(vo);
|
||||||
mp_notify(mpctx, MPV_EVENT_VIDEO_RECONFIG, NULL);
|
mp_notify(mpctx, MPV_EVENT_VIDEO_RECONFIG, NULL);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user