Skip to content
Permalink
Browse files

*** empty log message ***

  • Loading branch information
slouken committed Nov 15, 2004
1 parent c4cfe27 commit 58af5793969f5d7f28ddfd2b647bc5b2fe9ffa0a
Showing with 12 additions and 7 deletions.
  1. +0 −1 src/video/windib/SDL_dibevents.c
  2. +12 −6 src/video/windx5/SDL_dx5events.c
@@ -368,7 +368,6 @@ int DIB_CreateWindow(_THIS)
SDL_RegisterApp("SDL_app", CS_BYTEALIGNCLIENT, 0);
if ( SDL_windowid ) {
SDL_Window = (HWND)strtol(SDL_windowid, NULL, 0);

if ( SDL_Window == NULL ) {
SDL_SetError("Couldn't get user specified window");
return(-1);
@@ -849,14 +849,16 @@ int DX5_CreateWindow(_THIS)
SDL_RegisterApp("SDL_app", CS_BYTEALIGNCLIENT, 0);
if ( SDL_windowid ) {
SDL_Window = (HWND)strtol(SDL_windowid, NULL, 0);
if ( SDL_Window == NULL ) {
SDL_SetError("Couldn't get user specified window");
return(-1);
}

/* DJM: we want all event's for the user specified
window to be handled by SDL.
window to be handled by SDL.
*/
if (SDL_Window) {
userWindowProc = (WNDPROC)GetWindowLong(SDL_Window, GWL_WNDPROC);
SetWindowLong(SDL_Window, GWL_WNDPROC, (LONG)WinMessage);
}
userWindowProc = (WNDPROC)GetWindowLong(SDL_Window, GWL_WNDPROC);
SetWindowLong(SDL_Window, GWL_WNDPROC, (LONG)WinMessage);
} else {
SDL_Window = CreateWindow(SDL_Appname, SDL_Appname,
(WS_OVERLAPPED|WS_CAPTION|WS_SYSMENU|WS_MINIMIZEBOX),
@@ -883,5 +885,9 @@ void DX5_DestroyWindow(_THIS)
DX5_DInputQuit(this);

/* Destroy our window */
DestroyWindow(SDL_Window);
if ( SDL_windowid ) {
SetWindowLong(SDL_Window, GWL_WNDPROC, (LONG)userWindowProc);
} else {
DestroyWindow(SDL_Window);
}
}

0 comments on commit 58af579

Please sign in to comment.