Adapt to changes of Chrome 51 API changes (Part 2)
This commit is contained in:
parent
7ba391da7c
commit
a2bd55dd3c
48 changed files with 131 additions and 131 deletions
|
@ -7,7 +7,6 @@
|
|||
#include "atom/common/api/locker.h"
|
||||
#include "atom/common/node_includes.h"
|
||||
#include "base/memory/scoped_ptr.h"
|
||||
#include "third_party/WebKit/public/web/WebScopedMicrotaskSuppression.h"
|
||||
|
||||
namespace mate {
|
||||
|
||||
|
@ -17,9 +16,11 @@ v8::Local<v8::Value> CallEmitWithArgs(v8::Isolate* isolate,
|
|||
v8::Local<v8::Object> obj,
|
||||
ValueVector* args) {
|
||||
// Perform microtask checkpoint after running JavaScript.
|
||||
std::unique_ptr<blink::WebScopedRunV8Script> script_scope(
|
||||
std::unique_ptr<v8::MicrotasksScope> script_scope(
|
||||
Locker::IsBrowserProcess() ?
|
||||
nullptr : new blink::WebScopedRunV8Script);
|
||||
nullptr :
|
||||
new v8::MicrotasksScope(isolate,
|
||||
v8::MicrotasksScope::kRunMicrotasks));
|
||||
// Use node::MakeCallback to call the callback, and it will also run pending
|
||||
// tasks in Node.js.
|
||||
return node::MakeCallback(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue