SDL port code cleanup

This commit is contained in:
EkeEke 2012-10-22 15:58:50 +02:00
parent d6919657cb
commit 0ad41ad196
3 changed files with 8 additions and 6 deletions

View File

@ -41,7 +41,6 @@
****************************************************************************************/ ****************************************************************************************/
#include "shared.h" #include "shared.h"
#include <windows.h>
#include <zlib.h> #include <zlib.h>
static int check_zip(char *filename); static int check_zip(char *filename);

View File

@ -1,4 +1,8 @@
#ifdef __WIN32__
#include <windows.h> #include <windows.h>
#else
#define MessageBox(owner, text, caption, type) printf("%s: %s\n", caption, text)
#endif
#include "SDL.h" #include "SDL.h"
#include "SDL_thread.h" #include "SDL_thread.h"
@ -197,7 +201,8 @@ static void sdl_video_update()
/* clear destination surface */ /* clear destination surface */
SDL_FillRect(sdl_video.surf_screen, 0, 0); SDL_FillRect(sdl_video.surf_screen, 0, 0);
/*if (config.render && (interlaced || config.ntsc)) rect.h *= 2; #if 0
if (config.render && (interlaced || config.ntsc)) rect.h *= 2;
if (config.ntsc) rect.w = (reg[12]&1) ? MD_NTSC_OUT_WIDTH(rect.w) : SMS_NTSC_OUT_WIDTH(rect.w); if (config.ntsc) rect.w = (reg[12]&1) ? MD_NTSC_OUT_WIDTH(rect.w) : SMS_NTSC_OUT_WIDTH(rect.w);
if (config.ntsc) if (config.ntsc)
{ {
@ -233,7 +238,8 @@ static void sdl_video_update()
free(md_ntsc); free(md_ntsc);
md_ntsc = NULL; md_ntsc = NULL;
} }
} */ }
#endif
} }
SDL_BlitSurface(sdl_video.surf_bitmap, &sdl_video.srect, sdl_video.surf_screen, &sdl_video.drect); SDL_BlitSurface(sdl_video.surf_bitmap, &sdl_video.srect, sdl_video.surf_screen, &sdl_video.drect);
@ -658,8 +664,6 @@ int sdl_input_update(void)
break; break;
} }
} }
free (keystate);
return 1; return 1;
} }

View File

@ -6,7 +6,6 @@
#include <string.h> #include <string.h>
#include <stdarg.h> #include <stdarg.h>
#include <time.h> #include <time.h>
#include <conio.h>
#include <SDL.h> #include <SDL.h>
#include <stdlib.h> #include <stdlib.h>