[MPlayer-dev-eng] [PATCH] make enter in vo sdl usable

Christian Ohm chr.ohm at gmx.net
Sun Jun 16 01:30:59 CEST 2002


hi.

at the moment, when using vo sdl, enter quits mplayer when pressed twice.
very annoying, especially when you expect it to play the next file. this
patch removes this special behaviour.

bye
christian ohm

-- 
Are you a turtle?
-------------- next part --------------
Index: libvo/vo_sdl.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_sdl.c,v
retrieving revision 1.86
diff -u -r1.86 vo_sdl.c
--- libvo/vo_sdl.c	29 Apr 2002 09:52:21 -0000	1.86
+++ libvo/vo_sdl.c	15 Jun 2002 23:43:42 -0000
@@ -1188,7 +1188,7 @@
 	struct sdl_priv_s *priv = &sdl_priv;
 	SDL_Event event;
 	SDLKey keypressed = 0;
-	static int firstcheck = 0, modifiers = 0;
+	static int modifiers = 0;
 	
 	/* Poll the waiting SDL Events */
 	while ( SDL_PollEvent(&event) ) {
@@ -1307,8 +1307,7 @@
 				}	
 
                                 else switch(keypressed){
-				case SDLK_RETURN:
-					if (!firstcheck) { firstcheck = 1; break; }
+				case SDLK_RETURN: mplayer_put_key(KEY_ENTER);break;
                                 case SDLK_ESCAPE:
 				case SDLK_q:
 					SDL_ShowCursor(1);


More information about the MPlayer-dev-eng mailing list