aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar ben <ben@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-08-22 19:40:50 +0000
committerGravatar ben <ben@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-08-22 19:40:50 +0000
commit0edb9429c5cb6e38139528d0c901eb40e04894a0 (patch)
treef2e0112b8be1a291ff53ea866eaf45dd66930f6d
parent50cc36d3c6117a9f095559385ae8c58123f601cd (diff)
fix menu toggle/hide issues
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19495 b3059339-0415-0410-9bf9-f77b7e298cf2
-rw-r--r--libmenu/vf_menu.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libmenu/vf_menu.c b/libmenu/vf_menu.c
index 5601fdb323..6f5f039dca 100644
--- a/libmenu/vf_menu.c
+++ b/libmenu/vf_menu.c
@@ -101,7 +101,7 @@ static int cmd_filter(mp_cmd_t* cmd, int paused, struct vf_priv_s * priv) {
case MP_CMD_MENU : { // Convert txt cmd from the users into libmenu stuff
char* arg = cmd->args[0].v.s;
- if(!priv->current->show)
+ if(!priv->current->show && !(strcmp(arg,"hide") == 0) )
priv->current->show = 1;
else if(strcmp(arg,"up") == 0)
menu_read_cmd(priv->current,MENU_CMD_UP);
@@ -115,7 +115,7 @@ static int cmd_filter(mp_cmd_t* cmd, int paused, struct vf_priv_s * priv) {
menu_read_cmd(priv->current,MENU_CMD_OK);
else if(strcmp(arg,"cancel") == 0)
menu_read_cmd(priv->current,MENU_CMD_CANCEL);
- else if(strcmp(arg,"hide") == 0)
+ else if(strcmp(arg,"hide") == 0 || strcmp(arg,"toggle") == 0)
priv->current->show = 0;
else
mp_msg(MSGT_GLOBAL,MSGL_WARN,MSGTR_LIBMENU_UnknownMenuCommand,arg);