From dd9eba7447fab481e71ff92da70e0af11e952794 Mon Sep 17 00:00:00 2001 From: Shamus Hammons Date: Fri, 5 Sep 2003 18:07:57 +0000 Subject: [PATCH] Fixes to mouse support --- src/gui.cpp | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/src/gui.cpp b/src/gui.cpp index e1bf5c1..613cf88 100644 --- a/src/gui.cpp +++ b/src/gui.cpp @@ -20,9 +20,15 @@ using namespace std; // For STL stuff // Private function prototypes +// Local global variables + +int mouseX, mouseY; + void InitGUI(void) { + SDL_ShowCursor(SDL_DISABLE); + SDL_GetMouseState(&mouseX, &mouseY); } void GUIDone(void) @@ -95,7 +101,7 @@ bool UserSelectFile(char * path, char * filename) sort(fileList.begin(), fileList.end()); bool done = false; - uint32 limit = (fileList.size() > 24 ? 24 : fileList.size()); + uint32 limit = (fileList.size() > 30 ? 30 : fileList.size()); SDL_Event event; while (!done) @@ -103,7 +109,8 @@ bool UserSelectFile(char * path, char * filename) while (SDL_PollEvent(&event)) { // Draw the GUI... - memset(backbuffer, 0x11, tom_getVideoModeWidth() * tom_getVideoModeHeight() * 2); +// memset(backbuffer, 0x11, tom_getVideoModeWidth() * tom_getVideoModeHeight() * 2); + memset(backbuffer, 0x11, tom_getVideoModeWidth() * 240 * 2); for(uint32 i=0; i