src/video/windib/SDL_dibevents.c
changeset 1456 84de7511f79f
parent 1433 bb6839704ed6
child 1472 4aac8563c296
     1.1 --- a/src/video/windib/SDL_dibevents.c	Mon Feb 27 22:14:40 2006 +0000
     1.2 +++ b/src/video/windib/SDL_dibevents.c	Wed Mar 01 09:43:47 2006 +0000
     1.3 @@ -84,8 +84,7 @@
     1.4  
     1.5  
     1.6  /* The main Win32 event handler */
     1.7 -LONG
     1.8 - DIB_HandleMessage(_THIS, HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
     1.9 +LRESULT DIB_HandleMessage(_THIS, HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
    1.10  {
    1.11  	extern int posted;
    1.12  
    1.13 @@ -417,7 +416,7 @@
    1.14  		SDL_Window = (HWND)wcstol(windowid_t, NULL, 0);
    1.15  		SDL_free(windowid_t);
    1.16  #else
    1.17 -		SDL_Window = (HWND)SDL_strtol(windowid, NULL, 0);
    1.18 +		SDL_Window = (HWND)SDL_strtoull(windowid, NULL, 0);
    1.19  #endif
    1.20  		if ( SDL_Window == NULL ) {
    1.21  			SDL_SetError("Couldn't get user specified window");
    1.22 @@ -427,8 +426,8 @@
    1.23  		/* DJM: we want all event's for the user specified
    1.24  			window to be handled by SDL.
    1.25  		 */
    1.26 -		userWindowProc = (WNDPROCTYPE)GetWindowLong(SDL_Window, GWL_WNDPROC);
    1.27 -		SetWindowLong(SDL_Window, GWL_WNDPROC, (LONG)WinMessage);
    1.28 +		userWindowProc = (WNDPROCTYPE)GetWindowLongPtr(SDL_Window, GWL_WNDPROC);
    1.29 +		SetWindowLongPtr(SDL_Window, GWL_WNDPROC, (LONG_PTR)WinMessage);
    1.30  	} else {
    1.31  		SDL_Window = CreateWindow(SDL_Appname, SDL_Appname,
    1.32                          (WS_OVERLAPPED|WS_CAPTION|WS_SYSMENU|WS_MINIMIZEBOX),
    1.33 @@ -445,7 +444,7 @@
    1.34  void DIB_DestroyWindow(_THIS)
    1.35  {
    1.36  	if ( SDL_windowid ) {
    1.37 -		SetWindowLong(SDL_Window, GWL_WNDPROC, (LONG)userWindowProc);
    1.38 +		SetWindowLongPtr(SDL_Window, GWL_WNDPROC, (LONG_PTR)userWindowProc);
    1.39  	} else {
    1.40  		DestroyWindow(SDL_Window);
    1.41  	}