From ce236a1ca3574f230c150dff3a5bdd447e868ea5 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sat, 24 Aug 2013 07:36:34 +0000 Subject: - correct COM expors - various fixes git-svn-id: http://svn.miranda-ng.org/main/trunk@5804 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/ShellExt/src/shlcom.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'plugins/ShellExt/src/shlcom.cpp') diff --git a/plugins/ShellExt/src/shlcom.cpp b/plugins/ShellExt/src/shlcom.cpp index fbbf299894..11c6616116 100644 --- a/plugins/ShellExt/src/shlcom.cpp +++ b/plugins/ShellExt/src/shlcom.cpp @@ -1508,11 +1508,12 @@ void InvokeThreadServer() const IID CLSID_ISHLCOM = { 0x72013A26, 0xA94C, 0x11d6, {0x85, 0x40, 0xA5, 0xE6, 0x29, 0x32, 0x71, 0x1D }}; -HRESULT DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv) +STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv) { + MessageBoxA(0, "Ding!", "Dong", MB_OK); + if (rclsid == CLSID_ISHLCOM && riid == IID_IClassFactory && FindWindowA(MIRANDANAME, NULL) != 0) { *ppv = new TClassFactoryRec(); - MessageBoxA(0, "Ding!", "Dong", MB_OK); return S_OK; } @@ -1520,7 +1521,7 @@ HRESULT DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv) return CLASS_E_CLASSNOTAVAILABLE; } -HRESULT DllCanUnloadNow() +STDAPI DllCanUnloadNow() { if (dllobject.FactoryCount == 0 && dllobject.ObjectCount == 0) return S_OK; -- cgit v1.2.3