| 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 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 168 | 168 |
| 169 bool isAccelerationOptimalForCanvasContent() const; | 169 bool isAccelerationOptimalForCanvasContent() const; |
| 170 | 170 |
| 171 private: | 171 private: |
| 172 friend class CanvasRenderingContext2DAutoRestoreSkCanvas; | 172 friend class CanvasRenderingContext2DAutoRestoreSkCanvas; |
| 173 | 173 |
| 174 CanvasRenderingContext2D(HTMLCanvasElement*, const CanvasContextCreationAttr
ibutes& attrs, Document&); | 174 CanvasRenderingContext2D(HTMLCanvasElement*, const CanvasContextCreationAttr
ibutes& attrs, Document&); |
| 175 | 175 |
| 176 void dispose(); | 176 void dispose(); |
| 177 | 177 |
| 178 void dispatchContextLostEvent(Timer<CanvasRenderingContext2D>*); | 178 void dispatchContextLostEvent(TimerBase*); |
| 179 void dispatchContextRestoredEvent(Timer<CanvasRenderingContext2D>*); | 179 void dispatchContextRestoredEvent(TimerBase*); |
| 180 void tryRestoreContextEvent(Timer<CanvasRenderingContext2D>*); | 180 void tryRestoreContextEvent(TimerBase*); |
| 181 | 181 |
| 182 void unwindStateStack(); | 182 void unwindStateStack(); |
| 183 | 183 |
| 184 void pruneLocalFontCache(size_t targetSize); | 184 void pruneLocalFontCache(size_t targetSize); |
| 185 void schedulePruneLocalFontCacheIfNeeded(); | 185 void schedulePruneLocalFontCacheIfNeeded(); |
| 186 | 186 |
| 187 void scrollPathIntoViewInternal(const Path&); | 187 void scrollPathIntoViewInternal(const Path&); |
| 188 | 188 |
| 189 void drawTextInternal(const String&, double x, double y, CanvasRenderingCont
ext2DState::PaintType, double* maxWidth = nullptr); | 189 void drawTextInternal(const String&, double x, double y, CanvasRenderingCont
ext2DState::PaintType, double* maxWidth = nullptr); |
| 190 | 190 |
| (...skipping 29 matching lines...) Expand all Loading... |
| 220 HashMap<String, Font> m_fontsResolvedUsingCurrentStyle; | 220 HashMap<String, Font> m_fontsResolvedUsingCurrentStyle; |
| 221 bool m_pruneLocalFontCacheScheduled; | 221 bool m_pruneLocalFontCacheScheduled; |
| 222 ListHashSet<String> m_fontLRUList; | 222 ListHashSet<String> m_fontLRUList; |
| 223 }; | 223 }; |
| 224 | 224 |
| 225 DEFINE_TYPE_CASTS(CanvasRenderingContext2D, CanvasRenderingContext, context, con
text->is2d(), context.is2d()); | 225 DEFINE_TYPE_CASTS(CanvasRenderingContext2D, CanvasRenderingContext, context, con
text->is2d(), context.is2d()); |
| 226 | 226 |
| 227 } // namespace blink | 227 } // namespace blink |
| 228 | 228 |
| 229 #endif // CanvasRenderingContext2D_h | 229 #endif // CanvasRenderingContext2D_h |
| OLD | NEW |