Index: Source/core/dom/ProcessingInstruction.cpp |
diff --git a/Source/core/dom/ProcessingInstruction.cpp b/Source/core/dom/ProcessingInstruction.cpp |
index 1459449179d1f40f08a7bb9da07274463f9812cd..c3d42a1d562ad10facd600809d079c7df4bafa40 100644 |
--- a/Source/core/dom/ProcessingInstruction.cpp |
+++ b/Source/core/dom/ProcessingInstruction.cpp |
@@ -67,6 +67,23 @@ ProcessingInstruction::~ProcessingInstruction() |
if (inDocument() && m_isCSS) |
document().styleEngine()->removeStyleSheetCandidateNode(this); |
#endif |
+ clearEventListenerForXSLT(); |
+} |
+ |
+EventListener* ProcessingInstruction::eventListenerForXSLT() |
+{ |
+ if (!m_listenerForXSLT) |
+ return 0; |
+ |
+ return m_listenerForXSLT->toEventListener(); |
+} |
+ |
+void ProcessingInstruction::clearEventListenerForXSLT() |
+{ |
+ if (m_listenerForXSLT) { |
+ m_listenerForXSLT->detach(); |
+ m_listenerForXSLT.clear(); |
+ } |
} |
String ProcessingInstruction::nodeName() const |