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

Unified Diff: Source/WebCore/dom/Document.cpp

Issue 8273018: Merge 97402 - Source/WebCore: Register custom fonts at their creation time, rather than at retire... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/874/
Patch Set: Created 9 years, 2 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/WebCore/dom/Document.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/dom/Document.cpp
===================================================================
--- Source/WebCore/dom/Document.cpp (revision 97402)
+++ Source/WebCore/dom/Document.cpp (working copy)
@@ -574,7 +574,7 @@
(*m_userSheets)[i]->clearOwnerNode();
}
- deleteRetiredCustomFonts();
+ deleteCustomFonts();
m_weakReference->clear();
@@ -1564,15 +1564,6 @@
element->recalcStyle(change);
}
- // FIXME: Disabling the deletion of retired custom font data until
- // we fix all the stale style bugs (68804, 68624, etc). These bugs
- // indicate problems where some styles were not updated in recalcStyle,
- // thereby retaining stale copy of font data. To prevent that, we
- // disable this code for now and only delete retired custom font data
- // in Document destructor.
- // Now that all RenderStyles that pointed to retired fonts have been updated, the fonts can safely be deleted.
- // deleteRetiredCustomFonts();
-
#if USE(ACCELERATED_COMPOSITING)
if (view()) {
bool layoutPending = view()->layoutPending() || renderer()->needsLayout();
@@ -1709,18 +1700,18 @@
return style.release();
}
-void Document::retireCustomFont(FontData* fontData)
+void Document::registerCustomFont(FontData* fontData)
{
- m_retiredCustomFonts.append(adoptPtr(fontData));
+ m_customFonts.append(adoptPtr(fontData));
}
-void Document::deleteRetiredCustomFonts()
+void Document::deleteCustomFonts()
{
- size_t size = m_retiredCustomFonts.size();
+ size_t size = m_customFonts.size();
for (size_t i = 0; i < size; ++i)
- GlyphPageTreeNode::pruneTreeCustomFontData(m_retiredCustomFonts[i].get());
+ GlyphPageTreeNode::pruneTreeCustomFontData(m_customFonts[i].get());
- m_retiredCustomFonts.clear();
+ m_customFonts.clear();
}
bool Document::isPageBoxVisible(int pageIndex)
« no previous file with comments | « Source/WebCore/dom/Document.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698