forked from durs/node-activex
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
45 lines (35 loc) · 1.21 KB
/
Copy pathmain.cpp
File metadata and controls
45 lines (35 loc) · 1.21 KB
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
//-------------------------------------------------------------------------------------------------------
// Project: node-activex
// Author: Yuri Dursin
// Description: Defines the entry point for the NodeJS addon
//-------------------------------------------------------------------------------------------------------
#include "stdafx.h"
#include "disp.h"
//----------------------------------------------------------------------------------
namespace node_activex {
void Init(Local<Object> exports) {
DispObject::NodeInit(exports);
VariantObject::NodeInit(exports);
#ifdef TEST_ADVISE
ConnectionPointObject::NodeInit(exports);
#endif
}
NODE_MODULE(node_activex, Init)
}
//----------------------------------------------------------------------------------
BOOL APIENTRY DllMain(HMODULE hModule, DWORD ulReason, LPVOID lpReserved) {
switch (ulReason) {
case DLL_PROCESS_ATTACH:
CoInitialize(0);
break;
case DLL_PROCESS_DETACH:
CoUninitialize();
break;
case DLL_THREAD_ATTACH:
break;
case DLL_THREAD_DETACH:
break;
}
return TRUE;
}
//----------------------------------------------------------------------------------