| Index: Source/core/rendering/style/StyleRareNonInheritedData.cpp
|
| diff --git a/Source/core/rendering/style/StyleRareNonInheritedData.cpp b/Source/core/rendering/style/StyleRareNonInheritedData.cpp
|
| index f5a16f9a6dc449566e36ee044dee2096947038fe..7d1e8f50aeef45704a651865a3a3916b7898ea01 100644
|
| --- a/Source/core/rendering/style/StyleRareNonInheritedData.cpp
|
| +++ b/Source/core/rendering/style/StyleRareNonInheritedData.cpp
|
| @@ -22,6 +22,7 @@
|
| #include "config.h"
|
| #include "core/rendering/style/StyleRareNonInheritedData.h"
|
|
|
| +#include "core/dom/Document.h"
|
| #include "core/dom/WebCoreMemoryInstrumentation.h"
|
| #include "core/rendering/style/ContentData.h"
|
| #include "core/rendering/style/RenderStyle.h"
|
| @@ -52,6 +53,9 @@ StyleRareNonInheritedData::StyleRareNonInheritedData()
|
| , m_clipPath(RenderStyle::initialClipPath())
|
| , m_visitedLinkBackgroundColor(RenderStyle::initialBackgroundColor())
|
| , m_order(RenderStyle::initialOrder())
|
| +#if ENABLE(CSS_CALLBACKS)
|
| + , m_document()
|
| +#endif
|
| , m_flowThread(RenderStyle::initialFlowThread())
|
| , m_regionThread(RenderStyle::initialRegionThread())
|
| , m_regionFragment(RenderStyle::initialRegionFragment())
|
| @@ -124,6 +128,9 @@ StyleRareNonInheritedData::StyleRareNonInheritedData(const StyleRareNonInherited
|
| , m_visitedLinkBorderTopColor(o.m_visitedLinkBorderTopColor)
|
| , m_visitedLinkBorderBottomColor(o.m_visitedLinkBorderBottomColor)
|
| , m_order(o.m_order)
|
| +#if ENABLE(CSS_CALLBACKS)
|
| + , m_document()
|
| +#endif
|
| , m_flowThread(o.m_flowThread)
|
| , m_regionThread(o.m_regionThread)
|
| , m_regionFragment(o.m_regionFragment)
|
| @@ -156,6 +163,14 @@ StyleRareNonInheritedData::StyleRareNonInheritedData(const StyleRareNonInherited
|
|
|
| StyleRareNonInheritedData::~StyleRareNonInheritedData()
|
| {
|
| +#if ENABLE(CSS_CALLBACKS)
|
| + if (!m_callbackSelectors.isEmpty() && m_document.get()) {
|
| + Document* document = m_document.get();
|
| + for (Vector<String>::const_iterator it = m_callbackSelectors.begin(), end = m_callbackSelectors.end();
|
| + it != end; ++it)
|
| + document->removeSelectorMatch(*it);
|
| + }
|
| +#endif
|
| }
|
|
|
| bool StyleRareNonInheritedData::operator==(const StyleRareNonInheritedData& o) const
|
| @@ -199,6 +214,10 @@ bool StyleRareNonInheritedData::operator==(const StyleRareNonInheritedData& o) c
|
| && m_visitedLinkBorderTopColor == o.m_visitedLinkBorderTopColor
|
| && m_visitedLinkBorderBottomColor == o.m_visitedLinkBorderBottomColor
|
| && m_order == o.m_order
|
| +#if ENABLE(CSS_CALLBACKS)
|
| + && m_callbackSelectors == o.m_callbackSelectors
|
| + && m_document.get() == o.m_document.get()
|
| +#endif
|
| && m_flowThread == o.m_flowThread
|
| && m_regionThread == o.m_regionThread
|
| && m_regionFragment == o.m_regionFragment
|
|
|