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

Issue 7932007: Merge 94508 - <rdar://problem/10071256> Retain retired custom fonts until the next style recalc (Closed)

Created:
9 years, 3 months ago by bashi
Modified:
9 years, 3 months ago
Reviewers:
bashi
CC:
chromium-reviews
Base URL:
http://svn.webkit.org/repository/webkit/branches/chromium/835/
Visibility:
Public.

Description

Merge 94508 - <rdar://problem/10071256> Retain retired custom fonts until the next style recalc Reviewed by Darin Adler. Source/WebCore: Test: fast/css/font-face-used-after-retired.html During style recalc, existing renderers may reference their old style, including font data. Allow them to do so safely by keeping retired custom font data around until after style recalc. * css/CSSFontFace.cpp: (WebCore::CSSFontFace::retireCustomFont): Added. Calls through to CSSFontSelector, if the font face is still part of any segmented font face. Otherwise, deletes the custom font data. * css/CSSFontFace.h: * css/CSSFontFaceSource.cpp: (WebCore::CSSFontFaceSource::pruneTable): Changed to call retireCustomFont() instead of deleting retired font data. * css/CSSFontSelector.cpp: (WebCore::CSSFontSelector::retireCustomFont): Added. Calls through to the Document, if this is still the active font selector for a document. Otherwise, deletes the custom font data. * css/CSSFontSelector.h: * css/CSSSegmentedFontFace.cpp: (WebCore::CSSSegmentedFontFace::pruneTable): Changed to call retireCustomFont() instead of deleting retired font data. * dom/Document.cpp: (WebCore::Document::~Document): Added a call to deleteRetiredCustomFonts(), in case the Document is destroyed before getting a chance to recalc style after custom fonts have been retired. (WebCore::Document::recalcStyle): Added a call to deleteRetiredCustomFonts() after style recalc. (WebCore::Document::deleteRetiredCustomFonts): Added. Deletes all previously-retired custom font data. * dom/Document.h: (WebCore::Document::retireCustomFont): Added. LayoutTests: * fast/css/font-face-used-after-retired-expected.txt: Added. * fast/css/font-face-used-after-retired.html: Added. TBR=mitz@apple.com Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=95345

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+56 lines, -3 lines) Patch
A + LayoutTests/fast/css/font-face-used-after-retired.html View 0 chunks +-1 lines, --1 lines 0 comments Download
A + LayoutTests/fast/css/font-face-used-after-retired-expected.txt View 0 chunks +-1 lines, --1 lines 0 comments Download
M Source/WebCore/css/CSSFontFace.h View 1 chunk +1 line, -0 lines 0 comments Download
M Source/WebCore/css/CSSFontFace.cpp View 1 chunk +13 lines, -0 lines 0 comments Download
M Source/WebCore/css/CSSFontFaceSource.cpp View 1 chunk +3 lines, -2 lines 0 comments Download
M Source/WebCore/css/CSSFontSelector.h View 1 chunk +2 lines, -0 lines 0 comments Download
M Source/WebCore/css/CSSFontSelector.cpp View 1 chunk +10 lines, -0 lines 0 comments Download
M Source/WebCore/css/CSSSegmentedFontFace.cpp View 1 chunk +3 lines, -2 lines 0 comments Download
M Source/WebCore/dom/Document.h View 4 chunks +7 lines, -1 line 0 comments Download
M Source/WebCore/dom/Document.cpp View 3 chunks +19 lines, -0 lines 0 comments Download

Messages

Total messages: 1 (0 generated)
bashi
9 years, 3 months ago (2011-09-17 00:50:32 UTC) #1

          

Powered by Google App Engine
This is Rietveld 408576698