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

Side by Side Diff: Source/core/css/CSSFontFace.cpp

Issue 329143007: Fix some SVGFonts compilation errors (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase against ToT Created 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | Source/core/dom/custom/CustomElement.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008, 2011 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 { 60 {
61 if (m_segmentedFontFace) 61 if (m_segmentedFontFace)
62 m_segmentedFontFace->fontSelector()->fontFaceInvalidated(); 62 m_segmentedFontFace->fontSelector()->fontFaceInvalidated();
63 63
64 if (!isValid() || source != m_sources.first()) 64 if (!isValid() || source != m_sources.first())
65 return; 65 return;
66 66
67 if (loadStatus() == FontFace::Loading) { 67 if (loadStatus() == FontFace::Loading) {
68 if (source->ensureFontData()) { 68 if (source->ensureFontData()) {
69 setLoadStatus(FontFace::Loaded); 69 setLoadStatus(FontFace::Loaded);
70 #if ENABLE(SVG_FONTS)
70 Document* document = m_segmentedFontFace ? m_segmentedFontFace->font Selector()->document() : 0; 71 Document* document = m_segmentedFontFace ? m_segmentedFontFace->font Selector()->document() : 0;
71 if (document && source->isSVGFontFaceSource()) 72 if (document && source->isSVGFontFaceSource())
72 UseCounter::count(*document, UseCounter::SVGFontInCSS); 73 UseCounter::count(*document, UseCounter::SVGFontInCSS);
74 #endif
73 } else { 75 } else {
74 m_sources.removeFirst(); 76 m_sources.removeFirst();
75 load(); 77 load();
76 } 78 }
77 } 79 }
78 80
79 if (m_segmentedFontFace) 81 if (m_segmentedFontFace)
80 m_segmentedFontFace->fontLoaded(this); 82 m_segmentedFontFace->fontLoaded(this);
81 } 83 }
82 84
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 } 240 }
239 241
240 void CSSFontFace::trace(Visitor* visitor) 242 void CSSFontFace::trace(Visitor* visitor)
241 { 243 {
242 visitor->trace(m_segmentedFontFace); 244 visitor->trace(m_segmentedFontFace);
243 visitor->trace(m_sources); 245 visitor->trace(m_sources);
244 visitor->trace(m_fontFace); 246 visitor->trace(m_fontFace);
245 } 247 }
246 248
247 } 249 }
OLDNEW
« no previous file with comments | « no previous file | Source/core/dom/custom/CustomElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698