[PATCH 1/3] Add RegisterClassNameW() stub and cleanup module manifest to reflect current capabilities of class redirection

Nikolay Sivov bunglehead at gmail.com
Thu Dec 17 13:55:19 CST 2009


---
 dlls/comctl32/comctl32.spec |    1 +
 dlls/comctl32/commctrl.c    |   20 ++++++++++++--------
 include/winuser.h           |    3 +++
 3 files changed, 16 insertions(+), 8 deletions(-)

diff --git a/dlls/comctl32/comctl32.spec b/dlls/comctl32/comctl32.spec
index 4249d56..f0202ae 100644
--- a/dlls/comctl32/comctl32.spec
+++ b/dlls/comctl32/comctl32.spec
@@ -188,5 +188,6 @@
 @ stdcall PropertySheet(ptr) PropertySheetA
 @ stdcall PropertySheetA(ptr)
 @ stdcall PropertySheetW(ptr)
+@ stdcall RegisterClassNameW(wstr)
 @ stdcall UninitializeFlatSB(long)
 @ stdcall _TrackMouseEvent(ptr)
diff --git a/dlls/comctl32/commctrl.c b/dlls/comctl32/commctrl.c
index db0eade..9b56124 100644
--- a/dlls/comctl32/commctrl.c
+++ b/dlls/comctl32/commctrl.c
@@ -90,17 +90,9 @@ static const char manifest[] =
     "<assembly xmlns=\"urn:schemas-microsoft-com:asm.v1\" manifestVersion=\"1.0\">\n"
     "  <assemblyIdentity type=\"win32\" name=\"" NAME "\" version=\"" VERSION "\" processorArchitecture=\"" ARCH "\" publicKeyToken=\"" PUBLIC_KEY "\"/>\n"
     "  <file name=\"" FILE "\">\n"
-    "    <windowClass>Button</windowClass>\n"
-    "    <windowClass>ButtonListBox</windowClass>\n"
     "    <windowClass>ComboBoxEx32</windowClass>\n"
-    "    <windowClass>ComboLBox</windowClass>\n"
-    "    <windowClass>Combobox</windowClass>\n"
-    "    <windowClass>Edit</windowClass>\n"
-    "    <windowClass>Listbox</windowClass>\n"
     "    <windowClass>NativeFontCtl</windowClass>\n"
     "    <windowClass>ReBarWindow32</windowClass>\n"
-    "    <windowClass>ScrollBar</windowClass>\n"
-    "    <windowClass>Static</windowClass>\n"
     "    <windowClass>SysAnimate32</windowClass>\n"
     "    <windowClass>SysDateTimePick32</windowClass>\n"
     "    <windowClass>SysHeader32</windowClass>\n"
@@ -1692,3 +1684,15 @@ int WINAPI DrawShadowText(HDC hdc, LPCWSTR pszText, UINT cch, RECT *rect, DWORD
                                                                   crText, crShadow, ixOffset, iyOffset);
     return DrawTextW(hdc, pszText, cch, rect, DT_LEFT);
 }
+
+/***********************************************************************
+ * RegisterClassNameW [COMCTL32.@]
+ *
+ * Register window class again while using as SxS module.
+ */
+BOOLEAN WINAPI RegisterClassNameW(LPCWSTR className)
+{
+    /* FIXME: actually register redirected user32 class,
+              comctl32 classes are registered by this module anyway */
+    return TRUE;
+}
diff --git a/include/winuser.h b/include/winuser.h
index 91fca34..b8aad38 100644
--- a/include/winuser.h
+++ b/include/winuser.h
@@ -5086,6 +5086,9 @@ WINUSERAPI INT         WINAPI wvsprintfA(LPSTR,LPCSTR,__ms_va_list);
 WINUSERAPI INT         WINAPI wvsprintfW(LPWSTR,LPCWSTR,__ms_va_list);
 #define                       wvsprintf WINELIB_NAME_AW(wvsprintf)
 
+/* window class redirection prototype */
+typedef BOOLEAN (WINAPI *PREGISTERCLASSNAMEW)(LPCWSTR);
+
 /* Undocumented functions */
 
 /* NOTE: This is SYSTEM.3, not USER.182, which is also named KillSystemTimer */
-- 
1.5.6.5


--=-3vckwBinS0pstGlDlP/6--




More information about the wine-patches mailing list