| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef SuspendableScriptRunner_h |
| 6 #define SuspendableScriptRunner_h |
| 7 |
| 8 #include "core/dom/ActiveDOMObject.h" |
| 9 #include "wtf/Vector.h" |
| 10 |
| 11 namespace blink { |
| 12 |
| 13 class LocalFrame; |
| 14 class ScriptSourceCode; |
| 15 class WebScriptCallback; |
| 16 |
| 17 class SuspendableScriptRunner final : public ActiveDOMObject { |
| 18 public: |
| 19 SuspendableScriptRunner(LocalFrame*, int worldID, const Vector<ScriptSourceC
ode>& sources, int extensionGroup, WebScriptCallback*); |
| 20 virtual ~SuspendableScriptRunner(); |
| 21 |
| 22 void run(); |
| 23 |
| 24 virtual void resume() override; |
| 25 |
| 26 virtual void contextDestroyed() override; |
| 27 |
| 28 private: |
| 29 void execute(); |
| 30 |
| 31 LocalFrame* m_frame; |
| 32 int m_worldID; |
| 33 Vector<ScriptSourceCode> m_sources; |
| 34 int m_extensionGroup; |
| 35 WebScriptCallback* m_callback; |
| 36 }; |
| 37 |
| 38 } // namespace blink |
| 39 |
| 40 #endif // SuspendableScriptRunner_h |
| OLD | NEW |