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

Side by Side Diff: third_party/WebKit/Source/platform/fonts/FontFallbackList.cpp

Issue 2615813003: Migrate WTF::Vector::append() to ::push_back() [part 14 of N] (Closed)
Patch Set: rebase, small fix in FontSettings.h Created 3 years, 11 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. 2 * Copyright (C) 2006 Apple Computer, 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 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 return 0; 226 return 0;
227 227
228 // Ask the font cache for the font data. 228 // Ask the font cache for the font data.
229 // We are obtaining this font for the first time. We keep track of the 229 // We are obtaining this font for the first time. We keep track of the
230 // families we've looked at before in |m_familyIndex|, so that we never scan 230 // families we've looked at before in |m_familyIndex|, so that we never scan
231 // the same spot in the list twice. getFontData will adjust our 231 // the same spot in the list twice. getFontData will adjust our
232 // |m_familyIndex| as it scans for the right font to make. 232 // |m_familyIndex| as it scans for the right font to make.
233 ASSERT(FontCache::fontCache()->generation() == m_generation); 233 ASSERT(FontCache::fontCache()->generation() == m_generation);
234 RefPtr<FontData> result = getFontData(fontDescription, m_familyIndex); 234 RefPtr<FontData> result = getFontData(fontDescription, m_familyIndex);
235 if (result) { 235 if (result) {
236 m_fontList.append(result); 236 m_fontList.push_back(result);
237 if (result->isLoadingFallback()) 237 if (result->isLoadingFallback())
238 m_hasLoadingFallback = true; 238 m_hasLoadingFallback = true;
239 } 239 }
240 return result.get(); 240 return result.get();
241 } 241 }
242 242
243 bool FontFallbackList::isValid() const { 243 bool FontFallbackList::isValid() const {
244 if (!m_fontSelector) 244 if (!m_fontSelector)
245 return m_fontSelectorVersion == 0; 245 return m_fontSelectorVersion == 0;
246 246
247 return m_fontSelector->version() == m_fontSelectorVersion; 247 return m_fontSelector->version() == m_fontSelectorVersion;
248 } 248 }
249 249
250 } // namespace blink 250 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698