| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2009, 2010, 2011, 2012 Apple Inc. All rights | 2 * Copyright (C) 2006, 2007, 2009, 2010, 2011, 2012 Apple Inc. All rights |
| 3 * reserved. | 3 * reserved. |
| 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 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 192 bool isAccelerationOptimalForCanvasContent() const; | 192 bool isAccelerationOptimalForCanvasContent() const; |
| 193 | 193 |
| 194 void resetUsageTracking(); | 194 void resetUsageTracking(); |
| 195 | 195 |
| 196 void incrementFrameCount() { m_usageCounters.numFramesSinceReset++; } | 196 void incrementFrameCount() { m_usageCounters.numFramesSinceReset++; } |
| 197 | 197 |
| 198 bool isPaintable() const final { return hasImageBuffer(); } | 198 bool isPaintable() const final { return hasImageBuffer(); } |
| 199 | 199 |
| 200 ColorBehavior drawImageColorBehavior() const final; | 200 ColorBehavior drawImageColorBehavior() const final; |
| 201 | 201 |
| 202 void willDrawImage(CanvasImageSource*) const final; |
| 203 |
| 202 private: | 204 private: |
| 203 friend class CanvasRenderingContext2DAutoRestoreSkCanvas; | 205 friend class CanvasRenderingContext2DAutoRestoreSkCanvas; |
| 204 | 206 |
| 205 CanvasRenderingContext2D(HTMLCanvasElement*, | 207 CanvasRenderingContext2D(HTMLCanvasElement*, |
| 206 const CanvasContextCreationAttributes& attrs, | 208 const CanvasContextCreationAttributes& attrs, |
| 207 Document&); | 209 Document&); |
| 208 | 210 |
| 209 void dispose(); | 211 void dispose(); |
| 210 | 212 |
| 211 void dispatchContextLostEvent(TimerBase*); | 213 void dispatchContextLostEvent(TimerBase*); |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 | 263 |
| 262 DEFINE_TYPE_CASTS(CanvasRenderingContext2D, | 264 DEFINE_TYPE_CASTS(CanvasRenderingContext2D, |
| 263 CanvasRenderingContext, | 265 CanvasRenderingContext, |
| 264 context, | 266 context, |
| 265 context->is2d() && context->canvas(), | 267 context->is2d() && context->canvas(), |
| 266 context.is2d() && context.canvas()); | 268 context.is2d() && context.canvas()); |
| 267 | 269 |
| 268 } // namespace blink | 270 } // namespace blink |
| 269 | 271 |
| 270 #endif // CanvasRenderingContext2D_h | 272 #endif // CanvasRenderingContext2D_h |
| OLD | NEW |