| Index: Source/platform/graphics/RecordingImageBufferSurface.h
|
| diff --git a/Source/platform/graphics/RecordingImageBufferSurface.h b/Source/platform/graphics/RecordingImageBufferSurface.h
|
| index c8af6a045081ddfc38190d3bd03f27eb84842e20..79bbbf7ee30ed5fc5617aa7d8eccf2e45e7f0280 100644
|
| --- a/Source/platform/graphics/RecordingImageBufferSurface.h
|
| +++ b/Source/platform/graphics/RecordingImageBufferSurface.h
|
| @@ -7,6 +7,8 @@
|
|
|
| #include "platform/graphics/ImageBufferSurface.h"
|
| #include "public/platform/WebThread.h"
|
| +#include "third_party/skia/include/core/SkCanvas.h"
|
| +#include "wtf/LinkedStack.h"
|
| #include "wtf/OwnPtr.h"
|
| #include "wtf/RefPtr.h"
|
|
|
| @@ -34,11 +36,22 @@ public:
|
| virtual void setImageBuffer(ImageBuffer*) OVERRIDE;
|
|
|
| private:
|
| + struct StateRec {
|
| + public:
|
| + SkMatrix m_ctm;
|
| + SkIRect m_clip;
|
| + };
|
| + typedef LinkedStack<StateRec> StateStack;
|
| friend class ::RecordingImageBufferSurfaceTest; // for unit testing
|
| void fallBackToRasterCanvas();
|
| void initializeCurrentFrame();
|
| bool finalizeFrameInternal();
|
|
|
| + // saves current clip and transform matrix of canvas
|
| + bool saveState(SkCanvas*, StateStack*);
|
| + // we should make sure that we can transfer state in saveState
|
| + void setCurrentState(SkCanvas*, StateStack*);
|
| +
|
| OwnPtr<SkPictureRecorder> m_currentFrame;
|
| RefPtr<SkPicture> m_previousFrame;
|
| OwnPtr<SkCanvas> m_rasterCanvas;
|
|
|