| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_BITMAP_PLATFORM_DEVICE_LINUX_H_ | 5 #ifndef SKIA_EXT_BITMAP_PLATFORM_DEVICE_LINUX_H_ |
| 6 #define SKIA_EXT_BITMAP_PLATFORM_DEVICE_LINUX_H_ | 6 #define SKIA_EXT_BITMAP_PLATFORM_DEVICE_LINUX_H_ |
| 7 | 7 |
| 8 #include "base/ref_counted.h" | 8 #include "base/ref_counted.h" |
| 9 #include "skia/ext/platform_device_linux.h" | 9 #include "skia/ext/platform_device_linux.h" |
| 10 | 10 |
| 11 typedef struct _cairo_surface cairo_surface_t; | 11 typedef struct _cairo_surface cairo_surface_t; |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 BitmapPlatformDevice& operator=(const BitmapPlatformDevice& other); | 78 BitmapPlatformDevice& operator=(const BitmapPlatformDevice& other); |
| 79 | 79 |
| 80 // A stub copy constructor. Needs to be properly implemented. | 80 // A stub copy constructor. Needs to be properly implemented. |
| 81 BitmapPlatformDevice(const BitmapPlatformDevice& other); | 81 BitmapPlatformDevice(const BitmapPlatformDevice& other); |
| 82 | 82 |
| 83 // Bitmaps aren't vector graphics. | 83 // Bitmaps aren't vector graphics. |
| 84 virtual bool IsVectorial() { return false; } | 84 virtual bool IsVectorial() { return false; } |
| 85 | 85 |
| 86 // If someone wants to paint on a Cairo surface version of our | 86 // If someone wants to paint on a Cairo surface version of our |
| 87 // buffer, then give them the surface we're already using. | 87 // buffer, then give them the surface we're already using. |
| 88 virtual cairo_surface_t* beginPlatformPaint() { return surface(); } | 88 virtual cairo_t* beginPlatformPaint(); |
| 89 | 89 |
| 90 cairo_surface_t* surface() const; | 90 // Loads the given transform and clipping region into the HDC. This is |
| 91 // overridden from SkDevice. |
| 92 virtual void setMatrixClip(const SkMatrix& transform, const SkRegion& region); |
| 91 | 93 |
| 92 private: | 94 private: |
| 93 scoped_refptr<BitmapPlatformDeviceData> data_; | 95 scoped_refptr<BitmapPlatformDeviceData> data_; |
| 94 }; | 96 }; |
| 95 | 97 |
| 96 } // namespace skia | 98 } // namespace skia |
| 97 | 99 |
| 98 #endif // SKIA_EXT_BITMAP_PLATFORM_DEVICE_LINUX_H_ | 100 #endif // SKIA_EXT_BITMAP_PLATFORM_DEVICE_LINUX_H_ |
| OLD | NEW |