mirror of https://github.com/mpv-player/mpv
option to display menu at startup, patch by Aurelien Jacobs <aurel at gnuage.org>
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@13345 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
5e00ed042b
commit
0e339fc397
|
@ -82,6 +82,10 @@ extern int vo_nomouse_input;
|
|||
extern int WinID;
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_MENU
|
||||
extern int menu_startup;
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_AA
|
||||
extern int vo_aa_parseoption(m_option_t* conf, char *opt, char * param);
|
||||
extern void vo_aa_revertoption(m_option_t* opt,char* param);
|
||||
|
@ -331,6 +335,7 @@ m_option_t mplayer_opts[]={
|
|||
{"nomenu", &use_menu, CONF_TYPE_FLAG, CONF_GLOBAL, 1, 0, NULL},
|
||||
{"menu-root", &menu_root, CONF_TYPE_STRING, CONF_GLOBAL, 0, 0, NULL},
|
||||
{"menu-cfg", &menu_cfg, CONF_TYPE_STRING, CONF_GLOBAL, 0, 0, NULL},
|
||||
{"menu-startup", &menu_startup, CONF_TYPE_FLAG, CONF_GLOBAL, 0, 1, NULL},
|
||||
#else
|
||||
{"menu", "OSD menu support was not compiled in.\n", CONF_TYPE_PRINT,0, 0, 0, NULL},
|
||||
#endif
|
||||
|
|
|
@ -29,6 +29,8 @@ static struct vf_priv_s* st_priv = NULL;
|
|||
|
||||
static mp_image_t* pause_mpi = NULL;
|
||||
static int go2pause = 0;
|
||||
/// if nonzero display menu at startup
|
||||
int menu_startup = 0;
|
||||
|
||||
struct vf_priv_s {
|
||||
menu_t* root;
|
||||
|
@ -260,6 +262,7 @@ static int open(vf_instance_t *vf, char* args){
|
|||
st_priv = NULL;
|
||||
return 0;
|
||||
}
|
||||
st_priv->root->show = menu_startup;
|
||||
mp_input_add_cmd_filter((mp_input_cmd_filter)cmd_filter,st_priv);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue