OLD | NEW |
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 * (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org> | 3 * (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org> |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
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 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 m_clients.remove(client); | 76 m_clients.remove(client); |
77 } | 77 } |
78 #endif | 78 #endif |
79 | 79 |
80 void CSSFontSelector::dispatchInvalidationCallbacks() | 80 void CSSFontSelector::dispatchInvalidationCallbacks() |
81 { | 81 { |
82 m_fontFaceCache.incrementVersion(); | 82 m_fontFaceCache.incrementVersion(); |
83 | 83 |
84 WillBeHeapVector<RawPtrWillBeMember<CSSFontSelectorClient>> clients; | 84 WillBeHeapVector<RawPtrWillBeMember<CSSFontSelectorClient>> clients; |
85 copyToVector(m_clients, clients); | 85 copyToVector(m_clients, clients); |
86 // TODO(sof): the null check is temporarily in place to speculatively addres
s | 86 for (auto& client : clients) |
87 // crbug.com/568173. | 87 client->fontsNeedUpdate(this); |
88 for (auto& client : clients) { | |
89 if (client) | |
90 client->fontsNeedUpdate(this); | |
91 } | |
92 } | 88 } |
93 | 89 |
94 void CSSFontSelector::fontFaceInvalidated() | 90 void CSSFontSelector::fontFaceInvalidated() |
95 { | 91 { |
96 dispatchInvalidationCallbacks(); | 92 dispatchInvalidationCallbacks(); |
97 } | 93 } |
98 | 94 |
99 void CSSFontSelector::fontCacheInvalidated() | 95 void CSSFontSelector::fontCacheInvalidated() |
100 { | 96 { |
101 dispatchInvalidationCallbacks(); | 97 dispatchInvalidationCallbacks(); |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
189 #if ENABLE(OILPAN) | 185 #if ENABLE(OILPAN) |
190 visitor->trace(m_document); | 186 visitor->trace(m_document); |
191 visitor->trace(m_fontFaceCache); | 187 visitor->trace(m_fontFaceCache); |
192 visitor->trace(m_clients); | 188 visitor->trace(m_clients); |
193 visitor->trace(m_fontLoader); | 189 visitor->trace(m_fontLoader); |
194 #endif | 190 #endif |
195 FontSelector::trace(visitor); | 191 FontSelector::trace(visitor); |
196 } | 192 } |
197 | 193 |
198 } // namespace blink | 194 } // namespace blink |
OLD | NEW |