Jacek Caban : vbscript: Added Dll[Un]RegisterServer implementation.
Module: wine Branch: master Commit: bab84c0ebed3221a29d4960e705cd66577337eba URL: http://source.winehq.org/git/wine.git/?a=commit;h=bab84c0ebed3221a29d4960e70... Author: Jacek Caban <jacek(a)codeweavers.com> Date: Tue Jun 21 16:14:26 2011 +0200 vbscript: Added Dll[Un]RegisterServer implementation. --- dlls/vbscript/Makefile.in | 4 ++ dlls/vbscript/vbscript.rc | 24 +++++++++++++ dlls/vbscript/vbscript.rgs | 64 ++++++++++++++++++++++++++++++++++++ dlls/vbscript/vbscript_classes.idl | 50 ++++++++++++++++++++++++++++ dlls/vbscript/vbscript_main.c | 15 ++++++--- tools/wine.inf.in | 1 + 6 files changed, 153 insertions(+), 5 deletions(-) diff --git a/dlls/vbscript/Makefile.in b/dlls/vbscript/Makefile.in index 7b05715..c319b7d 100644 --- a/dlls/vbscript/Makefile.in +++ b/dlls/vbscript/Makefile.in @@ -3,4 +3,8 @@ MODULE = vbscript.dll C_SRCS = \ vbscript_main.c +RC_SRCS = vbscript.rc + +IDL_R_SRCS = vbscript_classes.idl + @MAKE_DLL_RULES@ diff --git a/dlls/vbscript/vbscript.rc b/dlls/vbscript/vbscript.rc new file mode 100644 index 0000000..311804f --- /dev/null +++ b/dlls/vbscript/vbscript.rc @@ -0,0 +1,24 @@ +/* + * Copyright 2011 Jacek Caban for CodeWeavers + * + * 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 + */ + +#include <windef.h> + +LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL + +/* @makedep: vbscript.rgs */ +2 WINE_REGISTRY vbscript.rgs diff --git a/dlls/vbscript/vbscript.rgs b/dlls/vbscript/vbscript.rgs new file mode 100644 index 0000000..7834e3e --- /dev/null +++ b/dlls/vbscript/vbscript.rgs @@ -0,0 +1,64 @@ +HKCR +{ + NoRemove CLSID + { + '{B54F3741-5B07-11CF-A4B0-00AA004A55E8}' + { + 'Implemented Categories' + { + '{f0b7a1a1-9847-11cf-8f20-00805f2cd064}' + '{f0b7a1a2-9847-11cf-8f20-00805f2cd064}' + } + OLEScript + } + '{B54F3742-5B07-11CF-A4B0-00AA004A55E8}' + { + 'Implemented Categories' + { + '{0aee2a92-bcbb-11d0-8c72-00c04fc2b085}' + } + OLEScript + } + '{B54F3743-5B07-11CF-A4B0-00AA004A55E8}' + { + 'Implemented Categories' + { + '{f0b7a1a1-9847-11cf-8f20-00805f2cd064}' + '{f0b7a1a2-9847-11cf-8f20-00805f2cd064}' + '{f0b7a1a3-9847-11cf-8f20-00805f2cd064}' + } + OLEScript + } + } + 'VBS' = s 'VB Script Language' + { + CLSID = s '{B54F3741-5B07-11CF-A4B0-00AA004A55E8}' + OLEScript + } + 'VBS Author' = s 'VB Script Language Authoring' + { + CLSID = s '{B54F3742-5B07-11CF-A4B0-00AA004A55E8}' + OLEScript + } + 'VBScript' + { + OLEScript + } + 'VBScript Author' + { + OLEScript + } + 'VBScript.Encode' + { + OLEScript + } + 'VBScript.RegExp' + { + OLEScript + } + ForceRemove '.vbs' = s 'VBSFile' + ForceRemove VBSFile = s 'VBScript Script File' + { + ScriptEngine = s 'VBScript' + } +} diff --git a/dlls/vbscript/vbscript_classes.idl b/dlls/vbscript/vbscript_classes.idl new file mode 100644 index 0000000..c800e1b --- /dev/null +++ b/dlls/vbscript/vbscript_classes.idl @@ -0,0 +1,50 @@ +/* + * Copyright 2011 Jacek Caban for CodeWeavers + * + * 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("VBScript Regular Expression"), + threading(apartment), + progid("VBScript.RegExp"), + version(5.5), + uuid(3f4daca4-160d-11d2-a8e9-00104b365c9f) +] +coclass VBScriptRegExp {} + +[ + helpstring("VB Script Language"), + threading(both), + progid("VBScript"), + uuid(b54f3741-5b07-11cf-a4b0-00aa004a55e8) +] +coclass VBScript {} + +[ + helpstring("VB Script Language Authoring"), + threading(both), + progid("VBScript Author"), + uuid(b54f3742-5b07-11cf-a4b0-00aa004a55e8) +] +coclass VBScriptAuthor {} + +[ + helpstring("VB Script Language Encoding"), + threading(both), + progid("VBScript.Encode"), + uuid(b54f3743-5b07-11cf-a4b0-00aa004a55e8) +] +coclass VBScriptEncode {} diff --git a/dlls/vbscript/vbscript_main.c b/dlls/vbscript/vbscript_main.c index f8b760e..fed2317 100644 --- a/dlls/vbscript/vbscript_main.c +++ b/dlls/vbscript/vbscript_main.c @@ -24,11 +24,15 @@ #include "windef.h" #include "winbase.h" +#include "ole2.h" +#include "rpcproxy.h" #include "wine/debug.h" WINE_DEFAULT_DEBUG_CHANNEL(vbscript); +static HINSTANCE vbscript_hinstance; + /****************************************************************** * DllMain (vbscript.@) */ @@ -41,7 +45,8 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpv) case DLL_WINE_PREATTACH: return FALSE; /* prefer native version */ case DLL_PROCESS_ATTACH: - DisableThreadLibraryCalls(hInstDLL); + DisableThreadLibraryCalls(hInstDLL); + vbscript_hinstance = hInstDLL; break; } @@ -71,8 +76,8 @@ HRESULT WINAPI DllCanUnloadNow(void) */ HRESULT WINAPI DllRegisterServer(void) { - FIXME("()\n"); - return S_OK; + TRACE("()\n"); + return __wine_register_resources(vbscript_hinstance, NULL); } /*********************************************************************** @@ -80,6 +85,6 @@ HRESULT WINAPI DllRegisterServer(void) */ HRESULT WINAPI DllUnregisterServer(void) { - FIXME("()\n"); - return S_OK; + TRACE("()\n"); + return __wine_unregister_resources(vbscript_hinstance, NULL); } diff --git a/tools/wine.inf.in b/tools/wine.inf.in index 8e8eba8..5493f60 100644 --- a/tools/wine.inf.in +++ b/tools/wine.inf.in @@ -2558,6 +2558,7 @@ HKLM,%CurrentVersion%\Telephony\Country List\998,"SameAreaRule",,"G" 11,,shdocvw.dll,1 11,,sti.dll,1 11,,urlmon.dll,1 +11,,vbscript.dll,1 11,,wbemprox.dll,1 11,,wiaservc.dll,1 11,,windowscodecs.dll,1
participants (1)
-
Alexandre Julliard