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

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

Issue 2268153002: Make PendingScript MemoryCoordinatorClient. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Check only whether m_streamer exists or not. Created 4 years, 4 months 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/dom/PendingScript.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/dom/PendingScript.h
diff --git a/third_party/WebKit/Source/core/dom/PendingScript.h b/third_party/WebKit/Source/core/dom/PendingScript.h
index 97e9b384b16140bf1bc67012b37f4b9105c432b5..96b16f6ea01e29b4bc42345f75e74e150b0c1f28 100644
--- a/third_party/WebKit/Source/core/dom/PendingScript.h
+++ b/third_party/WebKit/Source/core/dom/PendingScript.h
@@ -30,6 +30,7 @@
#include "core/CoreExport.h"
#include "core/fetch/ResourceOwner.h"
#include "core/fetch/ScriptResource.h"
+#include "platform/MemoryCoordinator.h"
#include "platform/heap/Handle.h"
#include "wtf/Noncopyable.h"
#include "wtf/text/TextPosition.h"
@@ -45,7 +46,7 @@ class ScriptSourceCode;
// A RefPtr alone does not prevent the underlying Resource
// from purging its data buffer. This class holds a dummy client open for its
// lifetime in order to guarantee that the data buffer will not be purged.
-class CORE_EXPORT PendingScript final : public GarbageCollectedFinalized<PendingScript>, public ResourceOwner<ScriptResource> {
+class CORE_EXPORT PendingScript final : public GarbageCollectedFinalized<PendingScript>, public ResourceOwner<ScriptResource>, public MemoryCoordinatorClient {
USING_GARBAGE_COLLECTED_MIXIN(PendingScript);
USING_PRE_FINALIZER(PendingScript, dispose);
WTF_MAKE_NONCOPYABLE(PendingScript);
@@ -88,6 +89,9 @@ public:
private:
PendingScript(Element*, ScriptResource*);
+ PendingScript() = delete;
+
+ void prepareToSuspend() override;
bool m_watchingForLoad;
Member<Element> m_element;
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/dom/PendingScript.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698