Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(278)

Unified Diff: third_party/WebKit/Source/core/dom/PendingScript.cpp

Issue 2463283002: Replace prepareToSuspend() with onMemoryStateChange(SUSPENDED) (Closed)
Patch Set: Remove prepareToSuspend Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/dom/PendingScript.cpp
diff --git a/third_party/WebKit/Source/core/dom/PendingScript.cpp b/third_party/WebKit/Source/core/dom/PendingScript.cpp
index 270cde456bc7af05605f6f0f273869830a54a54b..108e57b38d1980feb00d8eef5a012709fa67e656 100644
--- a/third_party/WebKit/Source/core/dom/PendingScript.cpp
+++ b/third_party/WebKit/Source/core/dom/PendingScript.cpp
@@ -222,7 +222,9 @@ bool PendingScript::errorOccurred() const {
return false;
}
-void PendingScript::prepareToSuspend() {
+void PendingScript::onMemoryStateChange(MemoryState state) {
+ if (state != MemoryState::SUSPENDED)
+ return;
if (!m_streamer)
return;
m_streamer->cancel();

Powered by Google App Engine
This is Rietveld 408576698