forked from bloomapi/node-freerdp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnode-freerdp.cc
29 lines (22 loc) · 898 Bytes
/
node-freerdp.cc
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
#include <nan.h>
#include "bridge.h"
using v8::FunctionTemplate;
using v8::Handle;
using v8::Object;
using v8::String;
using Nan::GetFunction;
using Nan::New;
using Nan::Set;
NAN_MODULE_INIT(InitAll) {
Set(target, New<String>("connect").ToLocalChecked(),
GetFunction(New<FunctionTemplate>(Connect)).ToLocalChecked());
Set(target, New<String>("sendKeyEventScancode").ToLocalChecked(),
GetFunction(New<FunctionTemplate>(SendKeyEventScancode)).ToLocalChecked());
Set(target, New<String>("sendPointerEvent").ToLocalChecked(),
GetFunction(New<FunctionTemplate>(SendPointerEvent)).ToLocalChecked());
Set(target, New<String>("setClipboard").ToLocalChecked(),
GetFunction(New<FunctionTemplate>(SetClipboard)).ToLocalChecked());
Set(target, New<String>("close").ToLocalChecked(),
GetFunction(New<FunctionTemplate>(Close)).ToLocalChecked());
}
NODE_MODULE(addon, InitAll)