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

Unified Diff: Source/modules/accessibility/AXImageMapLink.cpp

Issue 1072273006: Oilpan: Prepare moving AXObject to heap (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 6 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/modules/accessibility/AXImageMapLink.h ('k') | Source/modules/accessibility/AXInlineTextBox.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/accessibility/AXImageMapLink.cpp
diff --git a/Source/modules/accessibility/AXImageMapLink.cpp b/Source/modules/accessibility/AXImageMapLink.cpp
index 1d26401d4755a2eb79ab61d194e7432ed4608edc..443f35d6709a7c946b7c3c0c265ba89e29189f62 100644
--- a/Source/modules/accessibility/AXImageMapLink.cpp
+++ b/Source/modules/accessibility/AXImageMapLink.cpp
@@ -45,6 +45,15 @@ AXImageMapLink::AXImageMapLink(AXObjectCacheImpl& axObjectCache)
AXImageMapLink::~AXImageMapLink()
{
+ ASSERT(!m_areaElement);
+ ASSERT(!m_mapElement);
+}
+
+void AXImageMapLink::detach()
+{
+ AXMockObject::detach();
+ m_areaElement = nullptr;
+ m_mapElement = nullptr;
}
void AXImageMapLink::detachFromParent()
@@ -54,9 +63,9 @@ void AXImageMapLink::detachFromParent()
m_mapElement = nullptr;
}
-PassRefPtr<AXImageMapLink> AXImageMapLink::create(AXObjectCacheImpl& axObjectCache)
+PassRefPtrWillBeRawPtr<AXImageMapLink> AXImageMapLink::create(AXObjectCacheImpl& axObjectCache)
{
- return adoptRef(new AXImageMapLink(axObjectCache));
+ return adoptRefWillBeNoop(new AXImageMapLink(axObjectCache));
}
AXObject* AXImageMapLink::computeParent() const
@@ -141,4 +150,11 @@ LayoutRect AXImageMapLink::elementRect() const
return m_areaElement->computeRect(layoutObject);
}
+DEFINE_TRACE(AXImageMapLink)
+{
+ visitor->trace(m_areaElement);
+ visitor->trace(m_mapElement);
+ AXMockObject::trace(visitor);
+}
+
} // namespace blink
« no previous file with comments | « Source/modules/accessibility/AXImageMapLink.h ('k') | Source/modules/accessibility/AXInlineTextBox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698