OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef SKIA_EXT_VECTOR_PLATFORM_DEVICE_EMF_WIN_H_ | 5 #ifndef SKIA_EXT_VECTOR_PLATFORM_DEVICE_EMF_WIN_H_ |
6 #define SKIA_EXT_VECTOR_PLATFORM_DEVICE_EMF_WIN_H_ | 6 #define SKIA_EXT_VECTOR_PLATFORM_DEVICE_EMF_WIN_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 21 matching lines...) Expand all Loading... |
32 // Factory function. The DC is kept as the output context. | 32 // Factory function. The DC is kept as the output context. |
33 static VectorPlatformDeviceEmf* create(HDC dc, int width, int height); | 33 static VectorPlatformDeviceEmf* create(HDC dc, int width, int height); |
34 | 34 |
35 VectorPlatformDeviceEmf(HDC dc, const SkBitmap& bitmap); | 35 VectorPlatformDeviceEmf(HDC dc, const SkBitmap& bitmap); |
36 virtual ~VectorPlatformDeviceEmf(); | 36 virtual ~VectorPlatformDeviceEmf(); |
37 | 37 |
38 virtual SkDeviceFactory* getDeviceFactory() { | 38 virtual SkDeviceFactory* getDeviceFactory() { |
39 return SkNEW(VectorPlatformDeviceEmfFactory); | 39 return SkNEW(VectorPlatformDeviceEmfFactory); |
40 } | 40 } |
41 | 41 |
42 virtual HDC beginPlatformPaint() { | 42 virtual PlatformSurface BeginPlatformPaint(); |
43 return hdc_; | |
44 } | |
45 | 43 |
46 virtual void drawPaint(const SkDraw& draw, const SkPaint& paint) OVERRIDE; | 44 virtual void drawPaint(const SkDraw& draw, const SkPaint& paint) OVERRIDE; |
47 virtual void drawPoints(const SkDraw& draw, SkCanvas::PointMode mode, | 45 virtual void drawPoints(const SkDraw& draw, SkCanvas::PointMode mode, |
48 size_t count, const SkPoint[], | 46 size_t count, const SkPoint[], |
49 const SkPaint& paint) OVERRIDE; | 47 const SkPaint& paint) OVERRIDE; |
50 virtual void drawRect(const SkDraw& draw, const SkRect& r, | 48 virtual void drawRect(const SkDraw& draw, const SkRect& r, |
51 const SkPaint& paint) OVERRIDE; | 49 const SkPaint& paint) OVERRIDE; |
52 virtual void drawPath(const SkDraw& draw, const SkPath& path, | 50 virtual void drawPath(const SkDraw& draw, const SkPath& path, |
53 const SkPaint& paint, | 51 const SkPaint& paint, |
54 const SkMatrix* prePathMatrix = NULL, | 52 const SkMatrix* prePathMatrix = NULL, |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 // True if AlphaBlend() was called during this print. | 133 // True if AlphaBlend() was called during this print. |
136 bool alpha_blend_used_; | 134 bool alpha_blend_used_; |
137 | 135 |
138 DISALLOW_COPY_AND_ASSIGN(VectorPlatformDeviceEmf); | 136 DISALLOW_COPY_AND_ASSIGN(VectorPlatformDeviceEmf); |
139 }; | 137 }; |
140 | 138 |
141 } // namespace skia | 139 } // namespace skia |
142 | 140 |
143 #endif // SKIA_EXT_VECTOR_PLATFORM_DEVICE_EMF_WIN_H_ | 141 #endif // SKIA_EXT_VECTOR_PLATFORM_DEVICE_EMF_WIN_H_ |
144 | 142 |
OLD | NEW |