| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 00cca48 commit 7a17cbf
3 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -68,6 +68,7 @@ class ExternalReferenceRegistry { | |||
| 68 | 68 | V(report) \ | |
| 69 | 69 | V(task_queue) \ | |
| 70 | 70 | V(tcp_wrap) \ | |
| 71 | + V(tty_wrap) \ | ||
| 71 | 72 | V(url) \ | |
| 72 | 73 | V(util) \ | |
| 73 | 74 | V(serdes) \ | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -24,6 +24,7 @@ | |||
| 24 | 24 | #include "env-inl.h" | |
| 25 | 25 | #include "handle_wrap.h" | |
| 26 | 26 | #include "node_buffer.h" | |
| 27 | + #include "node_external_reference.h" | ||
| 27 | 28 | #include "stream_base-inl.h" | |
| 28 | 29 | #include "stream_wrap.h" | |
| 29 | 30 | #include "util-inl.h" | |
@@ -40,6 +41,13 @@ using v8::Object; | |||
| 40 | 41 | using v8::String; | |
| 41 | 42 | using v8::Value; | |
| 42 | 43 | ||
| 44 | + void TTYWrap::RegisterExternalReferences(ExternalReferenceRegistry* registry) { | ||
| 45 | + registry->Register(New); | ||
| 46 | + registry->Register(GetWindowSize); | ||
| 47 | + registry->Register(SetRawMode); | ||
| 48 | + registry->Register(IsTTY); | ||
| 49 | + } | ||
| 50 | + | ||
| 43 | 51 | void TTYWrap::Initialize(Local<Object> target, | |
| 44 | 52 | Local<Value> unused, | |
| 45 | 53 | Local<Context> context, | |
@@ -147,3 +155,5 @@ TTYWrap::TTYWrap(Environment* env, | |||
| 147 | 155 | } // namespace node | |
| 148 | 156 | ||
| 149 | 157 | NODE_MODULE_CONTEXT_AWARE_INTERNAL(tty_wrap, node::TTYWrap::Initialize) | |
| 158 | + NODE_MODULE_EXTERNAL_REFERENCE(tty_wrap, | ||
| 159 | + node::TTYWrap::RegisterExternalReferences) | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -30,13 +30,15 @@ | |||
| 30 | 30 | namespace node { | |
| 31 | 31 | ||
| 32 | 32 | class Environment; | |
| 33 | + class ExternalReferenceRegistry; | ||
| 33 | 34 | ||
| 34 | 35 | class TTYWrap : public LibuvStreamWrap { | |
| 35 | 36 | public: | |
| 36 | 37 | static void Initialize(v8::Local<v8::Object> target, | |
| 37 | 38 | v8::Local<v8::Value> unused, | |
| 38 | 39 | v8::Local<v8::Context> context, | |
| 39 | 40 | void* priv); | |
| 41 | + static void RegisterExternalReferences(ExternalReferenceRegistry* registry); | ||
| 40 | 42 | ||
| 41 | 43 | SET_NO_MEMORY_INFO() | |
| 42 | 44 | SET_MEMORY_INFO_NAME(TTYWrap) | |
| Back | FazBrowse Home | New Git URL |
0 commit comments