OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2009, 2010, 2011, 2012 Apple Inc. All rights reserv
ed. | 2 * Copyright (C) 2006, 2007, 2009, 2010, 2011, 2012 Apple Inc. All rights reserv
ed. |
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 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 | 172 |
173 void incrementFrameCount() { m_usageCounters.numFramesSinceReset++; }; | 173 void incrementFrameCount() { m_usageCounters.numFramesSinceReset++; }; |
174 | 174 |
175 private: | 175 private: |
176 friend class CanvasRenderingContext2DAutoRestoreSkCanvas; | 176 friend class CanvasRenderingContext2DAutoRestoreSkCanvas; |
177 | 177 |
178 CanvasRenderingContext2D(HTMLCanvasElement*, const CanvasContextCreationAttr
ibutes& attrs, Document&); | 178 CanvasRenderingContext2D(HTMLCanvasElement*, const CanvasContextCreationAttr
ibutes& attrs, Document&); |
179 | 179 |
180 void dispose(); | 180 void dispose(); |
181 | 181 |
182 void dispatchContextLostEvent(Timer<CanvasRenderingContext2D>*); | 182 void dispatchContextLostEvent(TimerBase*); |
183 void dispatchContextRestoredEvent(Timer<CanvasRenderingContext2D>*); | 183 void dispatchContextRestoredEvent(TimerBase*); |
184 void tryRestoreContextEvent(Timer<CanvasRenderingContext2D>*); | 184 void tryRestoreContextEvent(TimerBase*); |
185 | 185 |
186 void unwindStateStack(); | 186 void unwindStateStack(); |
187 | 187 |
188 void pruneLocalFontCache(size_t targetSize); | 188 void pruneLocalFontCache(size_t targetSize); |
189 void schedulePruneLocalFontCacheIfNeeded(); | 189 void schedulePruneLocalFontCacheIfNeeded(); |
190 | 190 |
191 void scrollPathIntoViewInternal(const Path&); | 191 void scrollPathIntoViewInternal(const Path&); |
192 | 192 |
193 void drawTextInternal(const String&, double x, double y, CanvasRenderingCont
ext2DState::PaintType, double* maxWidth = nullptr); | 193 void drawTextInternal(const String&, double x, double y, CanvasRenderingCont
ext2DState::PaintType, double* maxWidth = nullptr); |
194 | 194 |
(...skipping 29 matching lines...) Expand all Loading... |
224 HashMap<String, Font> m_fontsResolvedUsingCurrentStyle; | 224 HashMap<String, Font> m_fontsResolvedUsingCurrentStyle; |
225 bool m_pruneLocalFontCacheScheduled; | 225 bool m_pruneLocalFontCacheScheduled; |
226 ListHashSet<String> m_fontLRUList; | 226 ListHashSet<String> m_fontLRUList; |
227 }; | 227 }; |
228 | 228 |
229 DEFINE_TYPE_CASTS(CanvasRenderingContext2D, CanvasRenderingContext, context, con
text->is2d(), context.is2d()); | 229 DEFINE_TYPE_CASTS(CanvasRenderingContext2D, CanvasRenderingContext, context, con
text->is2d(), context.is2d()); |
230 | 230 |
231 } // namespace blink | 231 } // namespace blink |
232 | 232 |
233 #endif // CanvasRenderingContext2D_h | 233 #endif // CanvasRenderingContext2D_h |
OLD | NEW |