diff --git a/Atom-Linux/native_handler.cpp b/Atom-Linux/native_handler.cpp index 51b08ca3d..9ee59c25f 100644 --- a/Atom-Linux/native_handler.cpp +++ b/Atom-Linux/native_handler.cpp @@ -67,6 +67,14 @@ NativeHandler::NativeHandler() : object->SetValue(functionName, function, V8_PROPERTY_ATTRIBUTE_NONE); } + string nativePath = io_utils_real_app_path( + "/../src/stdlib/native-handler.js"); + if (!nativePath.empty()) { + string extensionCode; + if (io_utils_read(nativePath, &extensionCode) > 0) + CefRegisterExtension("v8/native-handler", extensionCode, this); + } + notifyFd = inotify_init(); if (notifyFd != -1) g_thread_create_full(NotifyWatchersCallback, this, 0, true, false, diff --git a/Atom/src/native_handler.mm b/Atom/src/native_handler.mm index 84f7b1d69..d891189ab 100644 --- a/Atom/src/native_handler.mm +++ b/Atom/src/native_handler.mm @@ -31,19 +31,9 @@ void throwException(const CefRefPtr& global, CefRefPtr