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

Unified Diff: Source/core/css/StyleSheetList.cpp

Issue 192473003: Move CSSRuleList to the garbage collected heap (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: ager feedback Created 6 years, 9 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/core/css/StyleSheetList.h ('k') | Source/core/css/resolver/StyleResolver.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/StyleSheetList.cpp
diff --git a/Source/core/css/StyleSheetList.cpp b/Source/core/css/StyleSheetList.cpp
index 38649f33e222f70d46ee8d2070543087ce56f5de..d05babe98264d49633570f7003207ce9b8cb99c2 100644
--- a/Source/core/css/StyleSheetList.cpp
+++ b/Source/core/css/StyleSheetList.cpp
@@ -40,7 +40,7 @@ StyleSheetList::~StyleSheetList()
{
}
-inline const Vector<RefPtr<StyleSheet> >& StyleSheetList::styleSheets()
+inline const WillBeHeapVector<RefPtrWillBeMember<StyleSheet> >& StyleSheetList::styleSheets()
{
if (!m_treeScope)
return m_detachedStyleSheets;
@@ -60,7 +60,7 @@ unsigned StyleSheetList::length()
StyleSheet* StyleSheetList::item(unsigned index)
{
- const Vector<RefPtr<StyleSheet> >& sheets = styleSheets();
+ const WillBeHeapVector<RefPtrWillBeMember<StyleSheet> >& sheets = styleSheets();
return index < sheets.size() ? sheets[index].get() : 0;
}
@@ -89,6 +89,7 @@ CSSStyleSheet* StyleSheetList::anonymousNamedGetter(const AtomicString& name)
void StyleSheetList::trace(Visitor* visitor)
{
+ visitor->trace(m_detachedStyleSheets);
}
} // namespace WebCore
« no previous file with comments | « Source/core/css/StyleSheetList.h ('k') | Source/core/css/resolver/StyleResolver.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698