Index: third_party/WebKit/Source/core/dom/ScriptRunner.cpp |
diff --git a/third_party/WebKit/Source/core/dom/ScriptRunner.cpp b/third_party/WebKit/Source/core/dom/ScriptRunner.cpp |
index e920985525b8a40556916dd69c65a948a99cc55d..740874b3b9e30555b82dff1bdc2958bb9b79dd70 100644 |
--- a/third_party/WebKit/Source/core/dom/ScriptRunner.cpp |
+++ b/third_party/WebKit/Source/core/dom/ScriptRunner.cpp |
@@ -129,18 +129,6 @@ |
} |
} |
-void ScriptRunner::scheduleReadyInOrderScripts() |
-{ |
- while (!m_pendingInOrderScripts.isEmpty() && m_pendingInOrderScripts.first()->isReady()) { |
- // A ScriptLoader that failed is responsible for cancelling itself |
- // notifyScriptLoadError(); it continues this draining of ready scripts. |
- if (m_pendingInOrderScripts.first()->errorOccurred()) |
- break; |
- m_inOrderScriptsToExecuteSoon.append(m_pendingInOrderScripts.takeFirst()); |
- postTask(BLINK_FROM_HERE); |
- } |
-} |
- |
void ScriptRunner::notifyScriptReady(ScriptLoader* scriptLoader, ExecutionType executionType) |
{ |
RELEASE_ASSERT_WITH_SECURITY_IMPLICATION(scriptLoader); |
@@ -163,7 +151,10 @@ |
RELEASE_ASSERT_WITH_SECURITY_IMPLICATION(m_numberOfInOrderScriptsWithPendingNotification > 0); |
m_numberOfInOrderScriptsWithPendingNotification--; |
- scheduleReadyInOrderScripts(); |
+ while (!m_pendingInOrderScripts.isEmpty() && m_pendingInOrderScripts.first()->isReady()) { |
+ m_inOrderScriptsToExecuteSoon.append(m_pendingInOrderScripts.takeFirst()); |
+ postTask(BLINK_FROM_HERE); |
+ } |
break; |
} |
@@ -205,7 +196,6 @@ |
foundLoader = foundLoader || m_isDisposed; |
#endif |
RELEASE_ASSERT_WITH_SECURITY_IMPLICATION(foundLoader); |
- scheduleReadyInOrderScripts(); |
break; |
} |
m_document->decrementLoadEventDelayCount(); |