msftedit: Explicitly load riched20 to make sure the window classes are created.
This commit is contained in:
parent
057c92db54
commit
bddb2e671b
|
@ -45,14 +45,20 @@ WINE_DEFAULT_DEBUG_CHANNEL(msftedit);
|
||||||
*/
|
*/
|
||||||
BOOL WINAPI DllMain(HINSTANCE inst, DWORD reason, LPVOID reserved)
|
BOOL WINAPI DllMain(HINSTANCE inst, DWORD reason, LPVOID reserved)
|
||||||
{
|
{
|
||||||
|
static const WCHAR riched20W[] = {'r','i','c','h','e','d','2','0','.','d','l','l',0};
|
||||||
|
static HMODULE richedit;
|
||||||
|
|
||||||
switch(reason)
|
switch(reason)
|
||||||
{
|
{
|
||||||
case DLL_WINE_PREATTACH:
|
case DLL_WINE_PREATTACH:
|
||||||
return FALSE; /* prefer native version */
|
return FALSE; /* prefer native version */
|
||||||
case DLL_PROCESS_ATTACH:
|
case DLL_PROCESS_ATTACH:
|
||||||
|
/* explicitly load riched20 since it creates the window classes at dll attach time */
|
||||||
|
richedit = LoadLibraryW( riched20W );
|
||||||
DisableThreadLibraryCalls(inst);
|
DisableThreadLibraryCalls(inst);
|
||||||
break;
|
break;
|
||||||
case DLL_PROCESS_DETACH:
|
case DLL_PROCESS_DETACH:
|
||||||
|
FreeLibrary( richedit );
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
Loading…
Reference in New Issue