forked from Niap/node-freerdp2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
node-freerdp2.cc
36 lines (24 loc) · 1.02 KB
/
node-freerdp2.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
30
31
32
33
34
35
36
#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>("sendClipboard").ToLocalChecked(),
GetFunction(New<FunctionTemplate>(SendClipboard)).ToLocalChecked());
Set(target, New<String>("close").ToLocalChecked(),
GetFunction(New<FunctionTemplate>(Close)).ToLocalChecked());
Set(target, New<String>("requestKeyframe").ToLocalChecked(),
GetFunction(New<FunctionTemplate>(RequestKeyframe)).ToLocalChecked());
}
NODE_MODULE(addon, InitAll)