Commit d8d1c9d6 authored by Sam Lantinga's avatar Sam Lantinga

Date: Sat, 06 Dec 2008 14:54:10 +0100

From: Couriersud
Subject: SDL: DirectFB mouse patch

the attached patch (again) properly registers the mouse in the DirectFB
driver.

--HG--
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%403302
parent 700f8221
...@@ -348,9 +348,11 @@ DirectFB_InitModes(_THIS) ...@@ -348,9 +348,11 @@ DirectFB_InitModes(_THIS)
display.driverdata = dispdata; display.driverdata = dispdata;
#if (DIRECTFB_MAJOR_VERSION == 1) && (DIRECTFB_MINOR_VERSION >= 2) #if (DIRECTFB_MAJOR_VERSION == 1) && (DIRECTFB_MINOR_VERSION >= 2)
dlc.flags = DLCONF_WIDTH | DLCONF_HEIGHT | DLCONF_PIXELFORMAT | DLCONF_OPTIONS; dlc.flags =
ret = layer->SetConfiguration(layer, &dlc); DLCONF_WIDTH | DLCONF_HEIGHT | DLCONF_PIXELFORMAT |
#endif DLCONF_OPTIONS;
ret = layer->SetConfiguration(layer, &dlc);
#endif
SDL_DFB_CHECKERR(layer->SetCooperativeLevel(layer, DLSCL_SHARED)); SDL_DFB_CHECKERR(layer->SetCooperativeLevel(layer, DLSCL_SHARED));
...@@ -467,7 +469,7 @@ DirectFB_SetDisplayMode(_THIS, SDL_DisplayMode * mode) ...@@ -467,7 +469,7 @@ DirectFB_SetDisplayMode(_THIS, SDL_DisplayMode * mode)
mode->format); mode->format);
return -1; return -1;
} }
data->pixelformat = rconfig.pixelformat; data->pixelformat = rconfig.pixelformat;
data->cw = config.width; data->cw = config.width;
data->ch = config.height; data->ch = config.height;
......
...@@ -49,7 +49,8 @@ DirectFB_InitMouse(_THIS) ...@@ -49,7 +49,8 @@ DirectFB_InitMouse(_THIS)
mouse.WarpMouse = DirectFB_WarpMouse; mouse.WarpMouse = DirectFB_WarpMouse;
mouse.FreeMouse = DirectFB_FreeMouse; mouse.FreeMouse = DirectFB_FreeMouse;
mouse.cursor_shown = 1; mouse.cursor_shown = 1;
devdata->mouse = SDL_AddMouse(&mouse, -1, "Mouse", 0, 0, 1); SDL_SetMouseIndexId(0, 0); /* ID == Index ! */
devdata->mouse = SDL_AddMouse(&mouse, 0, "Mouse", 0, 0, 1);
} }
void void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment