From 1c6d8ce568653c6702747ee13c5f73ce8037b746 Mon Sep 17 00:00:00 2001 From: Giannis Adamopoulos Date: Tue, 2 Aug 2011 13:54:41 +0000 Subject: [PATCH] [comctl32] - Register themed built-in controls even if themes are not enabled. This allows built in controls to use themes without restarting the application - Register built in controls in the same way it done in windows (as global classes that belong to comctl32). This is needed in order to have themed controls in dialogs. Unfortunately our user32/win32k does not support it yet and this breaks themed built in controls svn path=/branches/GSoC_2011/ThemesSupport/; revision=53029 --- dll/win32/comctl32/theming.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dll/win32/comctl32/theming.c b/dll/win32/comctl32/theming.c index 3ff6814c15b..f8d219874be 100644 --- a/dll/win32/comctl32/theming.c +++ b/dll/win32/comctl32/theming.c @@ -118,9 +118,7 @@ void THEMING_Initialize (void) { 'C','C','3','2','T','h','e','m','i','n','g','S','u','b','C','l',0 }; static const WCHAR refDataPropName[] = { 'C','C','3','2','T','h','e','m','i','n','g','D','a','t','a',0 }; - - if (!IsThemeActive()) return; - + atSubclassProp = GlobalAddAtomW (subclassPropName); atRefDataProp = GlobalAddAtomW (refDataPropName); @@ -133,6 +131,8 @@ void THEMING_Initialize (void) GetClassInfoExW (NULL, subclasses[i].className, &class); originalProcs[i] = class.lpfnWndProc; class.lpfnWndProc = subclassProcs[i]; + class.style |= CS_GLOBALCLASS; + class.hInstance = COMCTL32_hModule; if (!class.lpfnWndProc) {