OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009 Apple 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 * 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 20 matching lines...) Expand all Loading... |
31 #include "core/html/canvas/CanvasContextCreationAttributes.h" | 31 #include "core/html/canvas/CanvasContextCreationAttributes.h" |
32 #include "core/layout/HitTestCanvasResult.h" | 32 #include "core/layout/HitTestCanvasResult.h" |
33 #include "core/offscreencanvas/OffscreenCanvas.h" | 33 #include "core/offscreencanvas/OffscreenCanvas.h" |
34 #include "platform/graphics/ColorBehavior.h" | 34 #include "platform/graphics/ColorBehavior.h" |
35 #include "third_party/skia/include/core/SkColorSpace.h" | 35 #include "third_party/skia/include/core/SkColorSpace.h" |
36 #include "third_party/skia/include/core/SkImageInfo.h" | 36 #include "third_party/skia/include/core/SkImageInfo.h" |
37 #include "wtf/HashSet.h" | 37 #include "wtf/HashSet.h" |
38 #include "wtf/Noncopyable.h" | 38 #include "wtf/Noncopyable.h" |
39 #include "wtf/text/StringHash.h" | 39 #include "wtf/text/StringHash.h" |
40 | 40 |
41 class SkCanvas; | |
42 | |
43 namespace blink { | 41 namespace blink { |
44 | 42 |
45 class CanvasImageSource; | 43 class CanvasImageSource; |
46 class HTMLCanvasElement; | 44 class HTMLCanvasElement; |
47 class ImageData; | 45 class ImageData; |
48 class ImageBitmap; | 46 class ImageBitmap; |
49 class WebLayer; | 47 class WebLayer; |
50 | 48 |
51 enum CanvasColorSpace { | 49 enum CanvasColorSpace { |
52 kLegacyCanvasColorSpace, | 50 kLegacyCanvasColorSpace, |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 // Lost context provoked by WEBGL_lose_context. | 118 // Lost context provoked by WEBGL_lose_context. |
121 WebGLLoseContextLostContext, | 119 WebGLLoseContextLostContext, |
122 | 120 |
123 // Lost context occurred due to internal implementation reasons. | 121 // Lost context occurred due to internal implementation reasons. |
124 SyntheticLostContext, | 122 SyntheticLostContext, |
125 }; | 123 }; |
126 virtual void loseContext(LostContextMode) {} | 124 virtual void loseContext(LostContextMode) {} |
127 | 125 |
128 // Canvas2D-specific interface | 126 // Canvas2D-specific interface |
129 virtual bool is2d() const { return false; } | 127 virtual bool is2d() const { return false; } |
130 virtual void restoreCanvasMatrixClipStack(SkCanvas*) const {} | 128 virtual void restoreCanvasMatrixClipStack(PaintCanvas*) const {} |
131 virtual void reset() {} | 129 virtual void reset() {} |
132 virtual void clearRect(double x, double y, double width, double height) {} | 130 virtual void clearRect(double x, double y, double width, double height) {} |
133 virtual void didSetSurfaceSize() {} | 131 virtual void didSetSurfaceSize() {} |
134 virtual void setShouldAntialias(bool) {} | 132 virtual void setShouldAntialias(bool) {} |
135 virtual unsigned hitRegionsCount() const { return 0; } | 133 virtual unsigned hitRegionsCount() const { return 0; } |
136 virtual void setFont(const String&) {} | 134 virtual void setFont(const String&) {} |
137 virtual void styleDidChange(const ComputedStyle* oldStyle, | 135 virtual void styleDidChange(const ComputedStyle* oldStyle, |
138 const ComputedStyle& newStyle) {} | 136 const ComputedStyle& newStyle) {} |
139 virtual HitTestCanvasResult* getControlAndIdIfHitRegionExists( | 137 virtual HitTestCanvasResult* getControlAndIdIfHitRegionExists( |
140 const LayoutPoint& location) { | 138 const LayoutPoint& location) { |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
191 Member<OffscreenCanvas> m_offscreenCanvas; | 189 Member<OffscreenCanvas> m_offscreenCanvas; |
192 HashSet<String> m_cleanURLs; | 190 HashSet<String> m_cleanURLs; |
193 HashSet<String> m_dirtyURLs; | 191 HashSet<String> m_dirtyURLs; |
194 CanvasColorSpace m_colorSpace; | 192 CanvasColorSpace m_colorSpace; |
195 CanvasContextCreationAttributes m_creationAttributes; | 193 CanvasContextCreationAttributes m_creationAttributes; |
196 }; | 194 }; |
197 | 195 |
198 } // namespace blink | 196 } // namespace blink |
199 | 197 |
200 #endif | 198 #endif |
OLD | NEW |