diff options
author | Nicolas Bacca | 2002-10-24 22:06:01 +0000 |
---|---|---|
committer | Nicolas Bacca | 2002-10-24 22:06:01 +0000 |
commit | 45b12bc28605cdd3f9c583bb20ed97e5f5304c48 (patch) | |
tree | 6d09b8d31d35a2e33a0183a541cc7d6c6f718ce1 /backends/wince/pocketpc.cpp | |
parent | 52f544fbae6350237d0fbca218f76d0774ab5343 (diff) | |
download | scummvm-rg350-45b12bc28605cdd3f9c583bb20ed97e5f5304c48.tar.gz scummvm-rg350-45b12bc28605cdd3f9c583bb20ed97e5f5304c48.tar.bz2 scummvm-rg350-45b12bc28605cdd3f9c583bb20ed97e5f5304c48.zip |
Re-enable GameX (license ok), static link to mini-SDL & remove old GUI from project
svn-id: r5306
Diffstat (limited to 'backends/wince/pocketpc.cpp')
-rw-r--r-- | backends/wince/pocketpc.cpp | 42 |
1 files changed, 13 insertions, 29 deletions
diff --git a/backends/wince/pocketpc.cpp b/backends/wince/pocketpc.cpp index 51d1a592f2..7dde9cc016 100644 --- a/backends/wince/pocketpc.cpp +++ b/backends/wince/pocketpc.cpp @@ -50,10 +50,9 @@ #include "dynamic_imports.h" #if defined(MIPS) || defined(SH3) -#if 0 +// Comment this out if you don't want to support GameX #define GAMEX #endif -#endif #ifdef GAMEX #include "GameX.h" @@ -73,12 +72,13 @@ typedef BOOL (*tSHFullScreen)(HWND,DWORD); //typedef BOOL (WINSHELLAPI *tSHHandleWMSettingChange)(HWND,WPARAM,LPARAM,SHACTIVATEINFO*); typedef BOOL (*tSHSipPreference)(HWND,SIPSTATE); +/* // Dynamically linked SDLAudio typedef void (*tSDL_AudioQuit)(void); typedef int (*tSDL_Init)(Uint32); typedef void (*tSDL_PauseAudio)(int); typedef int (*tSDL_OpenAudio)(SDL_AudioSpec*, SDL_AudioSpec*); - +*/ // GAPI "emulation" typedef struct pseudoGAPI { @@ -130,6 +130,8 @@ int _pseudoGAPI_device; /* Default SDLAUDIO */ +/* + void defaultSDL_AudioQuit() { } @@ -144,6 +146,8 @@ int defaultSDL_OpenAudio(SDL_AudioSpec *desired, SDL_AudioSpec *obtained) { return 0; } +*/ + /* Default AYGSHELL */ BOOL defaultSHFullScreen(HWND handle, DWORD action) { @@ -320,10 +324,6 @@ int timer_interval; tSHFullScreen dynamicSHFullScreen = NULL; //tSHHandleWMSettingChange dynamicSHHandleWMSettingChange = NULL; tSHSipPreference dynamicSHSipPreference = NULL; -tSDL_AudioQuit dynamicSDL_AudioQuit = NULL; -tSDL_Init dynamicSDL_Init = NULL; -tSDL_PauseAudio dynamicSDL_PauseAudio = NULL; -tSDL_OpenAudio dynamicSDL_OpenAudio = NULL; tGXOpenInput dynamicGXOpenInput = NULL; tGXGetDefaultKeys dynamicGXGetDefaultKeys = NULL; tGXCloseDisplay dynamicGXCloseDisplay = NULL; @@ -588,7 +588,7 @@ void close_GAPI() { dynamicSHFullScreen(hWnd_Window, SHFS_SHOWTASKBAR | SHFS_SHOWSIPBUTTON | SHFS_SHOWSTARTICON); dynamicGXCloseInput(); dynamicGXCloseDisplay(); - dynamicSDL_AudioQuit(); + SDL_AudioQuit(); UpdateWindow(hWnd_Window); closing = true; } @@ -637,7 +637,7 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPWSTR lpCmdLin bool need_rescan = false; HMODULE aygshell_handle; - HMODULE SDLAudio_handle; + //HMODULE SDLAudio_handle; HMODULE GAPI_handle; hide_toolbar = false; @@ -655,22 +655,6 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPWSTR lpCmdLin //dynamicSHHandleWMSettingChange = defaultSHHandleWMSettingChange; } - // See if SDLAudio.dll is present - SDLAudio_handle = LoadLibrary(TEXT("SDLAudio.dll")); - if (SDLAudio_handle) { - IMPORT(SDLAudio_handle, dynamicSDL_AudioQuit, tSDL_AudioQuit, "SDL_AudioQuit") - IMPORT(SDLAudio_handle, dynamicSDL_Init, tSDL_Init, "SDL_Init") - IMPORT(SDLAudio_handle, dynamicSDL_PauseAudio, tSDL_PauseAudio, "SDL_PauseAudio") - IMPORT(SDLAudio_handle, dynamicSDL_OpenAudio, tSDL_OpenAudio, "SDL_OpenAudio") - } - else { - MessageBox(NULL, TEXT("SDLAudio.dll not found - games will play without sound"), TEXT("Missing DLL"), MB_OK); - dynamicSDL_AudioQuit = defaultSDL_AudioQuit; - dynamicSDL_Init = defaultSDL_Init; - dynamicSDL_PauseAudio = defaultSDL_PauseAudio; - dynamicSDL_OpenAudio = defaultSDL_OpenAudio; - } - // See if GX.dll is present GAPI_handle = LoadLibrary(TEXT("gx.dll")); if (GAPI_handle) { @@ -1354,7 +1338,7 @@ void action_boss() { g_scumm->saveState(g_scumm->_saveLoadSlot, g_scumm->_saveLoadCompatible); dynamicGXCloseInput(); dynamicGXCloseDisplay(); - dynamicSDL_AudioQuit(); + SDL_AudioQuit(); memset(&se, 0, sizeof(se)); se.cbSize = sizeof(se); se.hwnd = NULL; @@ -1469,7 +1453,7 @@ OSystem *OSystem_WINCE3::create(int gfx_mode, bool full_screen) { // Mini SDL init - if (dynamicSDL_Init(SDL_INIT_AUDIO)==-1) { + if (SDL_Init(SDL_INIT_AUDIO | SDL_INIT_TIMER)==-1) { exit(1); } @@ -1755,10 +1739,10 @@ bool OSystem_WINCE3::set_sound_proc(void *param, SoundProc *proc, byte format) { desired.samples = 128; desired.callback = own_soundProc; desired.userdata = param; - if (dynamicSDL_OpenAudio(&desired, NULL) != 0) { + if (SDL_OpenAudio(&desired, NULL) != 0) { return false; } - dynamicSDL_PauseAudio(0); + SDL_PauseAudio(0); return true; } |