[Mplayer-cvslog] CVS: main/libvo vo_sdl.c,1.30,1.31
Felix Buenemann
atmosfear at users.sourceforge.net
Sat May 5 23:38:35 CEST 2001
Update of /cvsroot/mplayer/main/libvo
In directory usw-pr-cvs1:/tmp/cvs-serv3385
Modified Files:
vo_sdl.c
Log Message:
Added workaround for buggy SDL versions (before 1.2.1).
Index: vo_sdl.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_sdl.c,v
retrieving revision 1.30
retrieving revision 1.31
diff -C2 -r1.30 -r1.31
*** vo_sdl.c 2001/05/05 20:13:37 1.30
--- vo_sdl.c 2001/05/05 21:38:33 1.31
***************
*** 97,100 ****
--- 97,102 ----
#undef SDL_NOHWSURFACE
+ //#define BUGGY_SDL //defined by configure
+
#include <stdio.h>
#include <stdlib.h>
***************
*** 806,810 ****
--- 808,830 ----
/* graphics mode selection shortcuts */
+ #ifdef BUGGY_SDL
case SDL_KEYDOWN:
+ switch(event.key.keysym.sym) {
+ case SDLK_UP: mplayer_put_key(KEY_UP);break;
+ case SDLK_DOWN: mplayer_put_key(KEY_DOWN);break;
+ case SDLK_LEFT: mplayer_put_key(KEY_LEFT);break;
+ case SDLK_RIGHT: mplayer_put_key(KEY_RIGHT);break;
+ case SDLK_ASTERISK:
+ case SDLK_KP_MULTIPLY:
+ case SDLK_w: mplayer_put_key('*');break;
+ case SDLK_SLASH:
+ case SDLK_KP_DIVIDE:
+ case SDLK_s: mplayer_put_key('/');break;
+ }
+ break;
+ case SDL_KEYUP:
+ #else
+ case SDL_KEYDOWN:
+ #endif
keypressed = event.key.keysym.sym;
if(verbose > 1) printf("SDL: Key pressed: '%i'\n", keypressed);
***************
*** 852,855 ****
--- 872,888 ----
case SDLK_PAGEUP: mplayer_put_key(KEY_PAGE_UP);break;
case SDLK_PAGEDOWN: mplayer_put_key(KEY_PAGE_DOWN);break;
+ #ifdef BUGGY_SDL
+ case SDLK_UP:
+ case SDLK_DOWN:
+ case SDLK_LEFT:
+ case SDLK_RIGHT:
+ case SDLK_ASTERISK:
+ case SDLK_KP_MULTIPLY:
+ case SDLK_w:
+ case SDLK_SLASH:
+ case SDLK_KP_DIVIDE:
+ case SDLK_s:
+ break;
+ #else
case SDLK_UP: mplayer_put_key(KEY_UP);break;
case SDLK_DOWN: mplayer_put_key(KEY_DOWN);break;
***************
*** 862,865 ****
--- 895,899 ----
case SDLK_KP_DIVIDE:
case SDLK_s: mplayer_put_key('/');break;
+ #endif
default:
mplayer_put_key(keypressed);
_______________________________________________
Mplayer-cvslog mailing list
Mplayer-cvslog at lists.sourceforge.net
http://lists.sourceforge.net/lists/listinfo/mplayer-cvslog
More information about the MPlayer-cvslog
mailing list