src/video/win32/SDL_win32window.c
changeset 2990 502adab079a4
parent 2971 a3012c6652ff
child 3045 9acb9f0f7f0d
     1.1 --- a/src/video/win32/SDL_win32window.c	Sun Jan 04 17:10:04 2009 +0000
     1.2 +++ b/src/video/win32/SDL_win32window.c	Sun Jan 04 17:14:27 2009 +0000
     1.3 @@ -318,7 +318,7 @@
     1.4      HWND hwnd = ((SDL_WindowData *) window->driverdata)->hwnd;
     1.5      HICON hicon = NULL;
     1.6  
     1.7 -    if(icon) {
     1.8 +    if (icon) {
     1.9          BYTE *icon_bmp;
    1.10          int icon_len;
    1.11          SDL_RWops *dst;
    1.12 @@ -337,7 +337,7 @@
    1.13          /* Write the BITMAPINFO header */
    1.14          SDL_WriteLE32(dst, 40);
    1.15          SDL_WriteLE32(dst, icon->w);
    1.16 -        SDL_WriteLE32(dst, icon->h*2);
    1.17 +        SDL_WriteLE32(dst, icon->h * 2);
    1.18          SDL_WriteLE16(dst, 1);
    1.19          SDL_WriteLE16(dst, 32);
    1.20          SDL_WriteLE32(dst, BI_RGB);
    1.21 @@ -355,22 +355,23 @@
    1.22              /* Write the pixels upside down into the bitmap buffer */
    1.23              int y = surface->h;
    1.24              while (y--) {
    1.25 -                Uint8 *src = (Uint8 *)surface->pixels + y * surface->pitch;
    1.26 +                Uint8 *src = (Uint8 *) surface->pixels + y * surface->pitch;
    1.27                  SDL_RWwrite(dst, src, surface->pitch, 1);
    1.28              }
    1.29              SDL_FreeSurface(surface);
    1.30  
    1.31 -            hicon = CreateIconFromResource(icon_bmp, icon_len, TRUE, 0x00030000);
    1.32 +            hicon =
    1.33 +                CreateIconFromResource(icon_bmp, icon_len, TRUE, 0x00030000);
    1.34          }
    1.35          SDL_RWclose(dst);
    1.36          SDL_stack_free(icon_bmp);
    1.37      }
    1.38  
    1.39      /* Set the icon for the window */
    1.40 -    SendMessage(hwnd, WM_SETICON, ICON_SMALL, (LPARAM)hicon);
    1.41 +    SendMessage(hwnd, WM_SETICON, ICON_SMALL, (LPARAM) hicon);
    1.42  
    1.43      /* Set the icon in the task manager (should we do this?) */
    1.44 -    SendMessage(hwnd, WM_SETICON, ICON_BIG, (LPARAM)hicon);
    1.45 +    SendMessage(hwnd, WM_SETICON, ICON_BIG, (LPARAM) hicon);
    1.46  }
    1.47  
    1.48  void