Index: Source/core/dom/ScriptRunner.h |
diff --git a/Source/core/dom/ScriptRunner.h b/Source/core/dom/ScriptRunner.h |
index e3236475d30eb1d3f5c92d34e6bfc0c1e8177bc0..ffd7bf2e9f80bf06c6fd0e4b4b79c7a7863055a9 100644 |
--- a/Source/core/dom/ScriptRunner.h |
+++ b/Source/core/dom/ScriptRunner.h |
@@ -38,6 +38,7 @@ |
class ScriptResource; |
class Document; |
+class PendingScript; |
class ScriptLoader; |
class ScriptRunner final : public NoBaseWillBeGarbageCollectedFinalized<ScriptRunner> { |
@@ -50,7 +51,7 @@ |
~ScriptRunner(); |
enum ExecutionType { ASYNC_EXECUTION, IN_ORDER_EXECUTION }; |
- void queueScriptForExecution(ScriptLoader*, ExecutionType); |
+ void queueScriptForExecution(ScriptLoader*, ResourcePtr<ScriptResource>, ExecutionType); |
bool hasPendingScripts() const { return !m_scriptsToExecuteSoon.isEmpty() || !m_scriptsToExecuteInOrder.isEmpty() || !m_pendingAsyncScripts.isEmpty(); } |
void suspend(); |
void resume(); |
@@ -66,12 +67,14 @@ |
void timerFired(Timer<ScriptRunner>*); |
- void addPendingAsyncScript(ScriptLoader*); |
+ void addPendingAsyncScript(ScriptLoader*, const PendingScript&); |
RawPtrWillBeMember<Document> m_document; |
- Vector<ScriptLoader*> m_scriptsToExecuteInOrder; |
- Vector<ScriptLoader*> m_scriptsToExecuteSoon; // http://www.whatwg.org/specs/web-apps/current-work/#set-of-scripts-that-will-execute-as-soon-as-possible |
- HashSet<ScriptLoader*> m_pendingAsyncScripts; |
+ // FIXME: Oilpan: consider using heap vectors and hash map here; |
+ // PendingScript does have a (trivial) destructor, however. |
+ Vector<PendingScript> m_scriptsToExecuteInOrder; |
+ Vector<PendingScript> m_scriptsToExecuteSoon; // http://www.whatwg.org/specs/web-apps/current-work/#set-of-scripts-that-will-execute-as-soon-as-possible |
+ WillBeHeapHashMap<ScriptLoader*, PendingScript> m_pendingAsyncScripts; |
Timer<ScriptRunner> m_timer; |
}; |