diff options
author | David-John Willis | 2012-07-23 22:28:10 +0100 |
---|---|---|
committer | David-John Willis | 2012-07-24 10:08:58 +0100 |
commit | 45354676ebe14df8d382681621f1d994258dbb72 (patch) | |
tree | d98f70af12f0de457d6f577f10c130cd573e0a0b /backends/platform/openpandora | |
parent | 3d395545cb1514ba4a07a785e58782462a3b1a94 (diff) | |
download | scummvm-rg350-45354676ebe14df8d382681621f1d994258dbb72.tar.gz scummvm-rg350-45354676ebe14df8d382681621f1d994258dbb72.tar.bz2 scummvm-rg350-45354676ebe14df8d382681621f1d994258dbb72.zip |
OPENPANDORA: Move SDL_CreateCursor hacklet from init to loadGFXMode.
* Fixes a bug that can occur on load.
Diffstat (limited to 'backends/platform/openpandora')
-rw-r--r-- | backends/platform/openpandora/op-backend.cpp | 55 |
1 files changed, 0 insertions, 55 deletions
diff --git a/backends/platform/openpandora/op-backend.cpp b/backends/platform/openpandora/op-backend.cpp index dcec387f97..47cff1c740 100644 --- a/backends/platform/openpandora/op-backend.cpp +++ b/backends/platform/openpandora/op-backend.cpp @@ -54,8 +54,6 @@ /* Dump console info to files. */ #define DUMP_STDOUT -static SDL_Cursor *hiddenCursor; - OSystem_OP::OSystem_OP() : OSystem_POSIX() { @@ -179,32 +177,12 @@ void OSystem_OP::initBackend() { /* Make sure SDL knows that we have a joystick we want to use. */ ConfMan.setInt("joystick_num", 0); -// _graphicsMutex = createMutex(); - /* Pass to POSIX method to do the heavy lifting */ OSystem_POSIX::initBackend(); _inited = true; } -// enable joystick -// if (joystick_num > -1 && SDL_NumJoysticks() > 0) { -// printf("Using joystick: %s\n", SDL_JoystickName(0)); -// _joystick = SDL_JoystickOpen(joystick_num); -// } -// -// setupMixer(); - -// Note: We could implement a custom SDLTimerManager by using -// SDL_AddTimer. That might yield better timer resolution, but it would -// also change the semantics of a timer: Right now, ScummVM timers -// *never* run in parallel, due to the way they are implemented. If we -// switched to SDL_AddTimer, each timer might run in a separate thread. -// However, not all our code is prepared for that, so we can't just -// switch. Still, it's a potential future change to keep in mind. -// _timer = new DefaultTimerManager(); -// _timerID = SDL_AddTimer(10, &timer_handler, _timer); - void OSystem_OP::initSDL() { // Check if SDL has not been initialized if (!_initedSDL) { @@ -217,38 +195,7 @@ void OSystem_OP::initSDL() { if (SDL_Init(sdlFlags) == -1) error("Could not initialize SDL: %s", SDL_GetError()); - uint8_t hiddenCursorData = 0; - - hiddenCursor = SDL_CreateCursor(&hiddenCursorData, &hiddenCursorData, 8, 1, 0, 0); - - /* On the OpenPandora we need to work around an SDL assumption that - returns relative mouse coordinates when you get to the screen - edges using the touchscreen. The workaround is to set a blank - SDL cursor and not disable it (Hackish I know). - - The root issues likes in the Windows Manager GRAB code in SDL. - That is why the issue is not seen on framebuffer devices like the - GP2X (there is no X window manager ;)). - */ - SDL_ShowCursor(SDL_ENABLE); - SDL_SetCursor(hiddenCursor); - SDL_EnableUNICODE(1); - -// memset(&_oldVideoMode, 0, sizeof(_oldVideoMode)); -// memset(&_videoMode, 0, sizeof(_videoMode)); -// memset(&_transactionDetails, 0, sizeof(_transactionDetails)); - -// _videoMode.mode = GFX_DOUBLESIZE; -// _videoMode.scaleFactor = 2; -// _videoMode.aspectRatioCorrection = ConfMan.getBool("aspect_ratio"); -// _scalerProc = Normal2x; -// _scalerType = 0; - -// _videoMode.fullscreen = true; - _initedSDL = true; - -// OSystem_POSIX::initSDL(); } } @@ -275,8 +222,6 @@ void OSystem_OP::addSysArchivesToSearchSet(Common::SearchSet &s, int priority) { void OSystem_OP::quit() { - SDL_FreeCursor(hiddenCursor); - #ifdef DUMP_STDOUT printf("%s\n", "Debug: STDOUT and STDERR text files closed."); fclose(stdout); |