[MPlayer-dev-eng] [PATCH] pause handling (2nd try)

Andreas Hess jaska at gmx.net
Thu Dec 26 14:39:04 CET 2002


Hi,

this patch enables anykey for un-pause, without a special command bind.


Andreas
-------------- next part --------------
Index: input/input.c
===================================================================
RCS file: /cvsroot/mplayer/main/input/input.c,v
retrieving revision 1.65
diff -u -r1.65 input.c
--- input/input.c	23 Dec 2002 01:37:42 -0000	1.65
+++ input/input.c	26 Dec 2002 13:32:13 -0000
@@ -742,10 +742,14 @@
   char* cmd = NULL;
   mp_cmd_t* ret;
 
-  if(cmd_binds)
-    cmd = mp_input_find_bind_for_key(cmd_binds,n,keys);
-  if(cmd == NULL)
-    cmd = mp_input_find_bind_for_key(def_cmd_binds,n,keys);
+  if(paused)
+    cmd = "pause";
+  else {
+    if(cmd_binds)
+      cmd = mp_input_find_bind_for_key(cmd_binds,n,keys);
+    if(cmd == NULL)
+      cmd = mp_input_find_bind_for_key(def_cmd_binds,n,keys);
+  }
 
   if(cmd == NULL) {
     mp_msg(MSGT_INPUT,MSGL_WARN,"No bind found for key %s",mp_input_get_key_name(keys[0]));


More information about the MPlayer-dev-eng mailing list