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

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

Issue 1238083002: Oilpan: Move the EventListener hierarchy to Oilpan's heap (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 5 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
Index: Source/core/dom/ProcessingInstruction.h
diff --git a/Source/core/dom/ProcessingInstruction.h b/Source/core/dom/ProcessingInstruction.h
index 72bf1b32e57f0fe962074f248398a4d7e19fa7c0..419100f5440b22c947aaac7440d9a993881e7bb5 100644
--- a/Source/core/dom/ProcessingInstruction.h
+++ b/Source/core/dom/ProcessingInstruction.h
@@ -54,24 +54,26 @@ public:
bool isLoading() const;
// For XSLT
- class DetachableEventListener {
+ class DetachableEventListener : public WillBeGarbageCollectedMixin {
public:
virtual ~DetachableEventListener() { }
-
- void ref() { refDetachableEventListener(); }
- void deref() { derefDetachableEventListener(); }
-
virtual EventListener* toEventListener() = 0;
-
// Detach event listener from its processing instruction.
virtual void detach() = 0;
+ DEFINE_INLINE_VIRTUAL_TRACE() { }
+
+#if !ENABLE(OILPAN)
+ void ref() { refDetachableEventListener(); }
+ void deref() { derefDetachableEventListener(); }
+
private:
virtual void refDetachableEventListener() = 0;
virtual void derefDetachableEventListener() = 0;
+#endif
};
- void setEventListenerForXSLT(PassRefPtr<DetachableEventListener> listener) { m_listenerForXSLT = listener; }
+ void setEventListenerForXSLT(PassRefPtrWillBeRawPtr<DetachableEventListener> listener) { m_listenerForXSLT = listener; }
EventListener* eventListenerForXSLT();
void clearEventListenerForXSLT();
@@ -107,7 +109,7 @@ private:
bool m_isCSS;
bool m_isXSL;
- RefPtr<DetachableEventListener> m_listenerForXSLT;
+ RefPtrWillBeMember<DetachableEventListener> m_listenerForXSLT;
};
DEFINE_NODE_TYPE_CASTS(ProcessingInstruction, nodeType() == Node::PROCESSING_INSTRUCTION_NODE);

Powered by Google App Engine
This is Rietveld 408576698