blob: 61d6898bfa5061ad515c3f2d2c4b61bb62c548aa (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
#include "precomp.h"
#pragma hdrstop
OBJECT_ENTRY_AUTO(__uuidof(SampleRadioManager), CSampleRadioManager);
class CSampleRadioModule : public CAtlDllModuleT<CSampleRadioModule>
{
public:
};
static CSampleRadioModule s_AtlModule;
//+---------------------------------------------------------------------------
// DLL Entry Point
//
EXTERN_C BOOL WINAPI DllMain
(
HINSTANCE /*hInstance*/,
DWORD dwReason,
LPVOID pvReserved
)
{
return s_AtlModule.DllMain(dwReason, pvReserved);
}
STDAPI DllCanUnloadNow(void)
{
return s_AtlModule.DllCanUnloadNow();
}
STDAPI DllGetClassObject(
_In_ REFCLSID rclsid,
_In_ REFIID riid,
_Outptr_ LPVOID* ppv
)
{
return s_AtlModule.DllGetClassObject(rclsid, riid, ppv);
}
//+---------------------------------------------------------------------------
// Adds entries to the system registry. Needed because the binary need copy to test machine.
// If binary is deployed by manifest, these functions are not needed.
STDAPI
DllRegisterServer ()
{
s_AtlModule.DllRegisterServer(FALSE);
return S_OK;
}
STDAPI
DllUnregisterServer ()
{
HRESULT hr = s_AtlModule.DllUnregisterServer();
return hr;
}
|