| Index: third_party/WebKit/Source/web/SuspendableScriptExecutor.h
|
| diff --git a/third_party/WebKit/Source/web/SuspendableScriptExecutor.h b/third_party/WebKit/Source/web/SuspendableScriptExecutor.h
|
| index 34f5477682f974fbb44bb97d1b3ddadb9db8d116..095926525cc0144701d6d65cd79c86ab72c6bc5e 100644
|
| --- a/third_party/WebKit/Source/web/SuspendableScriptExecutor.h
|
| +++ b/third_party/WebKit/Source/web/SuspendableScriptExecutor.h
|
| @@ -24,11 +24,14 @@ class SuspendableScriptExecutor final
|
| USING_GARBAGE_COLLECTED_MIXIN(SuspendableScriptExecutor);
|
|
|
| public:
|
| - static void createAndRun(LocalFrame*,
|
| - int worldID,
|
| - const HeapVector<ScriptSourceCode>& sources,
|
| - bool userGesture,
|
| - WebScriptExecutionCallback*);
|
| + enum BlockingOption { NonBlocking, OnloadBlocking };
|
| +
|
| + static SuspendableScriptExecutor* create(
|
| + LocalFrame*,
|
| + int worldID,
|
| + const HeapVector<ScriptSourceCode>& sources,
|
| + bool userGesture,
|
| + WebScriptExecutionCallback*);
|
| static void createAndRun(LocalFrame*,
|
| v8::Isolate*,
|
| v8::Local<v8::Context>,
|
| @@ -39,6 +42,8 @@ class SuspendableScriptExecutor final
|
| WebScriptExecutionCallback*);
|
| ~SuspendableScriptExecutor() override;
|
|
|
| + void run();
|
| + void runAsync(BlockingOption);
|
| void contextDestroyed(ExecutionContext*) override;
|
|
|
| DECLARE_VIRTUAL_TRACE();
|
| @@ -60,12 +65,12 @@ class SuspendableScriptExecutor final
|
|
|
| void fired() override;
|
|
|
| - void run();
|
| void executeAndDestroySelf();
|
| void dispose();
|
|
|
| RefPtr<ScriptState> m_scriptState;
|
| WebScriptExecutionCallback* m_callback;
|
| + BlockingOption m_blockingOption;
|
|
|
| SelfKeepAlive<SuspendableScriptExecutor> m_keepAlive;
|
|
|
|
|