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

Unified Diff: Source/core/dom/ScriptLoader.h

Issue 656413003: Revert of Oilpan: move ScriptLoader to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 2 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 | « Source/core/dom/PendingScript.h ('k') | Source/core/dom/ScriptLoader.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/ScriptLoader.h
diff --git a/Source/core/dom/ScriptLoader.h b/Source/core/dom/ScriptLoader.h
index 128b1fee35d1df43bed714b9a862428da2bf8dd8..d657e8316354301cbf3f07a7931d83d635b2c64b 100644
--- a/Source/core/dom/ScriptLoader.h
+++ b/Source/core/dom/ScriptLoader.h
@@ -36,15 +36,10 @@
class ScriptSourceCode;
-class ScriptLoader final : public NoBaseWillBeGarbageCollectedFinalized<ScriptLoader>, private ScriptResourceClient {
+class ScriptLoader final : private ScriptResourceClient {
public:
- static PassOwnPtrWillBeRawPtr<ScriptLoader> create(Element* element, bool createdByParser, bool isEvaluated)
- {
- return adoptPtrWillBeNoop(new ScriptLoader(element, createdByParser, isEvaluated));
- }
-
+ static PassOwnPtr<ScriptLoader> create(Element*, bool createdByParser, bool isEvaluated);
virtual ~ScriptLoader();
- virtual void trace(Visitor*);
Element* element() const { return m_element; }
@@ -93,14 +88,10 @@
// ResourceClient
virtual void notifyFinished(Resource*) override;
- RawPtrWillBeMember<Element> m_element;
+ // FIXME: Oilpan: This should become a Member once ResourceClient is moved to the heap.
+ Element* m_element;
ResourcePtr<ScriptResource> m_resource;
WTF::OrdinalNumber m_startLineNumber;
- String m_characterEncoding;
- String m_fallbackCharacterEncoding;
-
- PendingScript m_pendingScript;
-
bool m_parserInserted : 1;
bool m_isExternalScript : 1;
bool m_alreadyStarted : 1;
@@ -110,10 +101,20 @@
bool m_willExecuteWhenDocumentFinishedParsing : 1;
bool m_forceAsync : 1;
bool m_willExecuteInOrder : 1;
+ String m_characterEncoding;
+ String m_fallbackCharacterEncoding;
+
+ PendingScript m_pendingScript;
};
ScriptLoader* toScriptLoaderIfPossible(Element*);
-} // namespace blink
+inline PassOwnPtr<ScriptLoader> ScriptLoader::create(Element* element, bool createdByParser, bool isEvaluated)
+{
+ return adoptPtr(new ScriptLoader(element, createdByParser, isEvaluated));
+}
-#endif // ScriptLoader_h
+}
+
+
+#endif
« no previous file with comments | « Source/core/dom/PendingScript.h ('k') | Source/core/dom/ScriptLoader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698