diff options
author | Stefano Pigozzi <stefano.pigozzi@gmail.com> | 2014-12-07 12:49:07 +0100 |
---|---|---|
committer | Stefano Pigozzi <stefano.pigozzi@gmail.com> | 2014-12-07 16:22:38 +0100 |
commit | f56fcd71bbf302595afc19b3a8291cd47f485cfc (patch) | |
tree | 7bac0792bb3e12f75db9e6dad3d7dec11aafae71 /options | |
parent | 3afe76133b184260db726269d6495b5bbf044b4d (diff) |
options: add a 'once' idle mode
This allows to make mpv wait for file open events at start but close
after it is done playing the first playlist.
Diffstat (limited to 'options')
-rw-r--r-- | options/options.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/options/options.c b/options/options.c index 57cf20afa8..223c3ff666 100644 --- a/options/options.c +++ b/options/options.c @@ -541,7 +541,12 @@ const m_option_t mp_opts[] = { OPT_STRING("osd-msg2", osd_msg[1], 0), OPT_STRING("osd-msg3", osd_msg[2], 0), - OPT_FLAG("idle", player_idle_mode, M_OPT_GLOBAL), + OPT_CHOICE("idle", player_idle_mode, M_OPT_OPTIONAL_PARAM, + ({"no", 0}, + {"once", 1}, + {"yes", 2}, + {"", 2})), + OPT_FLAG("input-terminal", consolecontrols, CONF_GLOBAL), OPT_STRING("input-file", input_file, M_OPT_FILE | M_OPT_GLOBAL), |