Commit 0508dff0 authored by Alexandre Julliard's avatar Alexandre Julliard

mlang: Convert dll registration to the IRegistrar mechanism.

parent d1d90f4b
......@@ -5,7 +5,8 @@ DELAYIMPORTS = oleaut32
EXTRADEFS = -DCOM_NO_WINDOWS_H
C_SRCS = \
mlang.c \
regsvr.c
mlang.c
IDL_R_SRCS = mlang_classes.idl
@MAKE_DLL_RULES@
......@@ -33,6 +33,8 @@
#include "wingdi.h"
#include "winuser.h"
#include "ole2.h"
#include "objbase.h"
#include "rpcproxy.h"
#include "mlang.h"
#include "wine/unicode.h"
......@@ -47,6 +49,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(mlang);
static HRESULT MultiLanguage_create(IUnknown *pUnkOuter, LPVOID *ppObj);
static HRESULT EnumRfc1766_create(LANGID LangId, IEnumRfc1766 **ppEnum);
static HINSTANCE instance;
static DWORD MLANG_tls_index; /* to store various per thead data */
/* FIXME:
......@@ -879,6 +882,7 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpv)
{
switch(fdwReason) {
case DLL_PROCESS_ATTACH:
instance = hInstDLL;
MLANG_tls_index = TlsAlloc();
DisableThreadLibraryCalls(hInstDLL);
break;
......@@ -3587,6 +3591,23 @@ HRESULT WINAPI DllCanUnloadNow(void)
return dll_count == 0 ? S_OK : S_FALSE;
}
/***********************************************************************
* DllRegisterServer (MLANG.@)
*/
HRESULT WINAPI DllRegisterServer(void)
{
return __wine_register_resources( instance, NULL );
}
/***********************************************************************
* DllUnregisterServer (MLANG.@)
*/
HRESULT WINAPI DllUnregisterServer(void)
{
return __wine_unregister_resources( instance, NULL );
}
HRESULT WINAPI GetGlobalFontLinkObject(void)
{
FIXME("\n");
......
/*
* COM Classes for mlang
*
* Copyright 2010 Alexandre Julliard
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
[
helpstring("Multi Language Support"),
threading(both),
uuid(275c23e2-3747-11d0-9fea-00aa003f8646)
]
coclass CMultiLanguage { interface IMultiLanguage; }
[
helpstring("Multi Language String"),
threading(both),
uuid(c04d65cf-b70d-11d0-b188-00aa0038c969)
]
coclass CMLangString { interface IMultiLanguage; }
[
helpstring("Multi Language ConvertCharset"),
threading(both),
uuid(d66d6f99-cdaa-11d0-b822-00c04fc9b31f)
]
coclass CMLangConvertCharset { interface IMultiLanguage; }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment