Added SDL_SetWindowPosition() call to SDL_SetWindowShape(), going to see what this does on Windows.
authorEli Gottlieb <eligottlieb@gmail.com>
Thu, 12 Aug 2010 18:17:15 -0400
changeset 4848 40b46225e3cf
parent 4846 4f1573996a65
child 4849 0b918c186938
Added SDL_SetWindowPosition() call to SDL_SetWindowShape(), going to see what this does on Windows.
src/video/SDL_shape.c
src/video/win32/SDL_win32shape.c
--- a/src/video/SDL_shape.c	Tue Aug 10 16:10:26 2010 -0400
+++ b/src/video/SDL_shape.c	Thu Aug 12 18:17:15 2010 -0400
@@ -240,6 +240,7 @@
     result = window->display->device->shape_driver.SetWindowShape(window->shaper,shape,shapeMode);
     window->shaper->hasshape = SDL_TRUE;
     if((window->shaper->usershownflag & SDL_WINDOW_SHOWN) == SDL_WINDOW_SHOWN) {
+        SDL_SetWindowPosition(window,window->x,window->y);
         SDL_ShowWindow(window);
         window->shaper->usershownflag &= !SDL_WINDOW_SHOWN;
     }
--- a/src/video/win32/SDL_win32shape.c	Tue Aug 10 16:10:26 2010 -0400
+++ b/src/video/win32/SDL_win32shape.c	Thu Aug 12 18:17:15 2010 -0400
@@ -105,11 +105,11 @@
     /*
      * Set the new region mask for the window 
      */
-	mask_region = CreatePolyPolygonRgn(polygons,polygonVertexNumbers,num_rects,WINDING);
+    mask_region = CreatePolyPolygonRgn(polygons,polygonVertexNumbers,num_rects,WINDING);
     SetWindowRgn(((SDL_WindowData *)(shaper->window->driverdata))->hwnd, mask_region, TRUE);
 
-	SDL_free(polygons);
-	SDL_free(polygonVertexNumbers);
+    SDL_free(polygons);
+    SDL_free(polygonVertexNumbers);
     
     return 0;
 }