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

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

Issue 265793017: Oilpan: move node/element rare data objects to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebased + EventHandler.cpp oilpan compile fix Created 6 years, 8 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/ElementRareData.h
diff --git a/Source/core/dom/ElementRareData.h b/Source/core/dom/ElementRareData.h
index 631fc87e185c37584335185b1651808006ec640b..c1833a3c81ddfbc5e67980b963274d79b158fffd 100644
--- a/Source/core/dom/ElementRareData.h
+++ b/Source/core/dom/ElementRareData.h
@@ -32,6 +32,7 @@
#include "core/html/ClassList.h"
#include "core/html/ime/InputMethodContext.h"
#include "core/rendering/style/StyleInheritedData.h"
+#include "platform/heap/Handle.h"
#include "wtf/OwnPtr.h"
namespace WebCore {
@@ -40,9 +41,9 @@ class HTMLElement;
class ElementRareData : public NodeRareData {
public:
- static PassOwnPtr<ElementRareData> create(RenderObject* renderer)
+ static PassOwnPtrWillBeRawPtr<ElementRareData> create(RenderObject* renderer)
{
- return adoptPtr(new ElementRareData(renderer));
+ return adoptPtrWillBeNoop(new ElementRareData(renderer));
}
~ElementRareData();
@@ -122,6 +123,8 @@ public:
void setCustomElementDefinition(PassRefPtr<CustomElementDefinition> definition) { m_customElementDefinition = definition; }
CustomElementDefinition* customElementDefinition() const { return m_customElementDefinition.get(); }
+ void traceAfterDispatch(Visitor*);
+
private:
short m_tabindex;
@@ -133,7 +136,7 @@ private:
OwnPtr<ElementShadow> m_shadow;
OwnPtr<NamedNodeMap> m_attributeMap;
OwnPtr<InputMethodContext> m_inputMethodContext;
- OwnPtrWillBePersistent<ActiveAnimations> m_activeAnimations;
+ OwnPtrWillBeMember<ActiveAnimations> m_activeAnimations;
OwnPtr<InlineCSSStyleDeclaration> m_cssomWrapper;
RefPtr<RenderStyle> m_computedStyle;
@@ -156,11 +159,14 @@ inline ElementRareData::ElementRareData(RenderObject* renderer)
, m_tabindex(0)
, m_minimumSizeForResizing(defaultMinimumSizeForResizing())
{
+ m_isElementRareData = true;
}
inline ElementRareData::~ElementRareData()
{
+#if !ENABLE(OILPAN)
ASSERT(!m_shadow);
+#endif
ASSERT(!m_generatedBefore);
ASSERT(!m_generatedAfter);
ASSERT(!m_backdrop);

Powered by Google App Engine
This is Rietveld 408576698