Index: Source/platform/graphics/ImageBuffer.h |
diff --git a/Source/platform/graphics/ImageBuffer.h b/Source/platform/graphics/ImageBuffer.h |
index 7e7717f38ee020efe536f41cd74bac28531f4eec..5d8fb103fd7b87d83e16a3c2bc8c5a8690ca1483 100644 |
--- a/Source/platform/graphics/ImageBuffer.h |
+++ b/Source/platform/graphics/ImageBuffer.h |
@@ -55,6 +55,7 @@ namespace WebCore { |
class DrawingBuffer; |
class Image; |
+class ImageBufferClient; |
class IntPoint; |
class IntRect; |
@@ -81,8 +82,12 @@ public: |
~ImageBuffer(); |
+ void setClient(ImageBufferClient* client) { m_client = client; } |
+ |
const IntSize& size() const { return m_surface->size(); } |
bool isAccelerated() const { return m_surface->isAccelerated(); } |
+ bool isSurfaceValid() const; |
+ bool restoreSurface() const; |
void setIsHidden(bool hidden) { m_surface->setIsHidden(hidden); } |
@@ -117,9 +122,10 @@ public: |
void flush(); |
+ void notifySurfaceInvalid(); |
+ |
private: |
ImageBuffer(PassOwnPtr<ImageBufferSurface>); |
- bool isValid() const; |
void draw(GraphicsContext*, const FloatRect&, const FloatRect& = FloatRect(0, 0, -1, -1), CompositeOperator = CompositeSourceOver, blink::WebBlendMode = blink::WebBlendModeNormal); |
void drawPattern(GraphicsContext*, const FloatRect&, const FloatSize&, const FloatPoint&, CompositeOperator, const FloatRect&, blink::WebBlendMode, const IntSize& repeatSpacing = IntSize()); |
@@ -133,6 +139,7 @@ private: |
OwnPtr<ImageBufferSurface> m_surface; |
OwnPtr<GraphicsContext> m_context; |
+ ImageBufferClient* m_client; |
}; |
struct ImageDataBuffer { |