d3d10: COM cleanup for the ID3D10EffectType iface.
[wine] / dlls / user32 / desktop.c
index 37774b8..92ee21a 100644 (file)
 #include "windef.h"
 #include "winbase.h"
 #include "wingdi.h"
+#include "winnls.h"
 #include "controls.h"
-#include "wine/winuser16.h"
 
 static HBRUSH hbrushPattern;
 static HBITMAP hbitmapWallPaper;
 static SIZE bitmapSize;
 static BOOL fTileWallPaper;
 
-static LRESULT WINAPI DesktopWndProc( HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam );
-
 
 /*********************************************************************
  * desktop class descriptor
  */
 const struct builtin_class_descr DESKTOP_builtin_class =
 {
-    (LPCSTR)DESKTOP_CLASS_ATOM, /* name */
+    (LPCWSTR)DESKTOP_CLASS_ATOM, /* name */
     CS_DBLCLKS,           /* style */
-    NULL,                 /* procA (winproc is Unicode only) */
-    DesktopWndProc,       /* procW */
+    WINPROC_DESKTOP,      /* proc */
     0,                    /* extra */
     IDC_ARROW,            /* cursor */
     (HBRUSH)(COLOR_BACKGROUND+1)    /* brush */
@@ -115,7 +112,7 @@ static HBITMAP DESKTOP_LoadBitmap( HDC hdc, const char *filename )
 /***********************************************************************
  *           DesktopWndProc
  */
-static LRESULT WINAPI DesktopWndProc( HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam )
+LRESULT WINAPI DesktopWndProc( HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam )
 {
     if (message == WM_NCCREATE) return TRUE;
     return 0;  /* all other messages are ignored */
@@ -231,12 +228,12 @@ BOOL DESKTOP_SetPattern( LPCWSTR pattern )
                     &pat[0], &pat[1], &pat[2], &pat[3],
                     &pat[4], &pat[5], &pat[6], &pat[7] ))
         {
-            WORD pattern[8];
+            WORD ptrn[8];
             HBITMAP hbitmap;
             int i;
 
-            for (i = 0; i < 8; i++) pattern[i] = pat[i] & 0xffff;
-            hbitmap = CreateBitmap( 8, 8, 1, 1, (LPSTR)pattern );
+            for (i = 0; i < 8; i++) ptrn[i] = pat[i] & 0xffff;
+            hbitmap = CreateBitmap( 8, 8, 1, 1, ptrn );
             hbrushPattern = CreatePatternBrush( hbitmap );
             DeleteObject( hbitmap );
         }