comparison src/video/directfb/SDL_DirectFB_WM.c @ 4568:25b9cd8bdc30

Couriersud to Sam I have done some quick changes and at least the code compiles again. It also works with a number of the test executables with the DFB X11 backend. I hope to find time to get SDLMAME to work with latest SDL1.3 (i.e. rip out multi-keyboard, multi-mice & cursor support) next week to test it further. Regards, André
author Sam Lantinga <slouken@libsdl.org>
date Fri, 23 Jul 2010 21:33:00 -0700
parents f7b03b6838cb
children b196d2758026
comparison
equal deleted inserted replaced
4567:1d7ea8724f4a 4568:25b9cd8bdc30
208 DirectFB_WM_AdjustWindowLayout(window); 208 DirectFB_WM_AdjustWindowLayout(window);
209 209
210 windata->window->MoveTo(windata->window, 0, 0); 210 windata->window->MoveTo(windata->window, 0, 0);
211 windata->window->Resize(windata->window, 211 windata->window->Resize(windata->window,
212 display->current_mode.w, display->current_mode.h); 212 display->current_mode.w, display->current_mode.h);
213 SDL_SendWindowEvent(windata->sdl_id, SDL_WINDOWEVENT_MAXIMIZED, 0, 0); 213 SDL_SendWindowEvent(window, SDL_WINDOWEVENT_MAXIMIZED, 0, 0);
214 } 214 }
215 215
216 void 216 void
217 DirectFB_WM_RestoreWindow(_THIS, SDL_Window * window) 217 DirectFB_WM_RestoreWindow(_THIS, SDL_Window * window)
218 { 218 {
224 DirectFB_WM_AdjustWindowLayout(window); 224 DirectFB_WM_AdjustWindowLayout(window);
225 windata->window->MoveTo(windata->window, windata->restore.x, 225 windata->window->MoveTo(windata->window, windata->restore.x,
226 windata->restore.y); 226 windata->restore.y);
227 windata->window->Resize(windata->window, windata->restore.w, 227 windata->window->Resize(windata->window, windata->restore.w,
228 windata->restore.h); 228 windata->restore.h);
229 SDL_SendWindowEvent(windata->sdl_id, SDL_WINDOWEVENT_RESTORED, 0, 0); 229 SDL_SendWindowEvent(window, SDL_WINDOWEVENT_RESTORED, 0, 0);
230 } 230 }
231 231
232 enum 232 enum
233 { 233 {
234 WM_POS_NONE = 0x00, 234 WM_POS_NONE = 0x00,
302 int pos = WMPos(windata, evt->x, evt->y); 302 int pos = WMPos(windata, evt->x, evt->y);
303 switch (pos) { 303 switch (pos) {
304 case WM_POS_NONE: 304 case WM_POS_NONE:
305 return 0; 305 return 0;
306 case WM_POS_CLOSE: 306 case WM_POS_CLOSE:
307 SDL_SendWindowEvent(windata->sdl_id, SDL_WINDOWEVENT_CLOSE, 0, 307 SDL_SendWindowEvent(window, SDL_WINDOWEVENT_CLOSE, 0,
308 0); 308 0);
309 return 1; 309 return 1;
310 case WM_POS_MAX: 310 case WM_POS_MAX:
311 if (window->flags & SDL_WINDOW_MAXIMIZED) { 311 if (window->flags & SDL_WINDOW_MAXIMIZED) {
312 DirectFB_WM_RestoreWindow(_this, window); 312 DirectFB_WM_RestoreWindow(_this, window);