Mercurial > sdl-ios-xcode
diff src/video/win32/SDL_win32window.c @ 3685:64ce267332c6
Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Thu, 21 Jan 2010 06:21:52 +0000 |
parents | 07c8339c95c6 |
children | f7b03b6838cb |
line wrap: on
line diff
--- a/src/video/win32/SDL_win32window.c Thu Jan 21 05:49:41 2010 +0000 +++ b/src/video/win32/SDL_win32window.c Thu Jan 21 06:21:52 2010 +0000 @@ -86,7 +86,7 @@ SetupWindowData(_THIS, SDL_Window * window, HWND hwnd, SDL_bool created) { SDL_VideoData *videodata = (SDL_VideoData *) _this->driverdata; - SDL_VideoDisplay *display = SDL_GetDisplayFromWindow(window); + SDL_VideoDisplay *display = window->display; SDL_WindowData *data; /* Allocate the window data */ @@ -95,7 +95,7 @@ SDL_OutOfMemory(); return -1; } - data->windowID = window->id; + data->window = window; data->hwnd = hwnd; data->hdc = GetDC(hwnd); data->created = created; @@ -167,7 +167,7 @@ if (GetFocus() == hwnd) { int index = data->videodata->keyboard; window->flags |= SDL_WINDOW_INPUT_FOCUS; - SDL_SetKeyboardFocus(index, data->windowID); + SDL_SetKeyboardFocus(index, data->window); if (window->flags & SDL_WINDOW_INPUT_GRABBED) { RECT rect; @@ -187,7 +187,7 @@ WIN_CreateWindow(_THIS, SDL_Window * window) { SDL_VideoData *videodata = (SDL_VideoData *) _this->driverdata; - SDL_VideoDisplay *display = SDL_GetDisplayFromWindow(window); + SDL_VideoDisplay *display = window->display; RAWINPUTDEVICE Rid; AXIS TabX, TabY; LOGCONTEXTA lc; @@ -429,7 +429,7 @@ void WIN_SetWindowPosition(_THIS, SDL_Window * window) { - SDL_VideoDisplay *display = SDL_GetDisplayFromWindow(window); + SDL_VideoDisplay *display = window->display; HWND hwnd = ((SDL_WindowData *) window->driverdata)->hwnd; RECT rect; SDL_Rect bounds;