| 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_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 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "skia/ext/platform_device_linux.h" | 10 #include "skia/ext/platform_device_linux.h" |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 81 virtual ~BitmapPlatformDevice(); | 81 virtual ~BitmapPlatformDevice(); |
| 82 | 82 |
| 83 BitmapPlatformDevice& operator=(const BitmapPlatformDevice& other); | 83 BitmapPlatformDevice& operator=(const BitmapPlatformDevice& other); |
| 84 | 84 |
| 85 static BitmapPlatformDevice* Create(int width, int height, bool is_opaque); | 85 static BitmapPlatformDevice* Create(int width, int height, bool is_opaque); |
| 86 | 86 |
| 87 // This doesn't take ownership of |data| | 87 // This doesn't take ownership of |data| |
| 88 static BitmapPlatformDevice* Create(int width, int height, | 88 static BitmapPlatformDevice* Create(int width, int height, |
| 89 bool is_opaque, uint8_t* data); | 89 bool is_opaque, uint8_t* data); |
| 90 | 90 |
| 91 virtual void makeOpaque(int x, int y, int width, int height); | 91 virtual void MakeOpaque(int x, int y, int width, int height); |
| 92 | 92 |
| 93 // Overridden from SkDevice: | 93 // Overridden from SkDevice: |
| 94 virtual void setMatrixClip(const SkMatrix& transform, const SkRegion& region, | 94 virtual void setMatrixClip(const SkMatrix& transform, const SkRegion& region, |
| 95 const SkClipStack&); | 95 const SkClipStack&); |
| 96 | 96 |
| 97 // Overridden from PlatformDevice: | 97 // Overridden from PlatformDevice: |
| 98 virtual bool IsVectorial(); | 98 virtual bool IsVectorial(); |
| 99 virtual cairo_t* BeginPlatformPaint(); | 99 virtual cairo_t* BeginPlatformPaint(); |
| 100 | 100 |
| 101 protected: | 101 protected: |
| 102 // Override SkDevice. | 102 // Override SkDevice. |
| 103 virtual SkDeviceFactory* onNewDeviceFactory(); | 103 virtual SkDeviceFactory* onNewDeviceFactory(); |
| 104 | 104 |
| 105 private: | 105 private: |
| 106 static BitmapPlatformDevice* Create(int width, int height, bool is_opaque, | 106 static BitmapPlatformDevice* Create(int width, int height, bool is_opaque, |
| 107 cairo_surface_t* surface); | 107 cairo_surface_t* surface); |
| 108 | 108 |
| 109 scoped_refptr<BitmapPlatformDeviceData> data_; | 109 scoped_refptr<BitmapPlatformDeviceData> data_; |
| 110 }; | 110 }; |
| 111 | 111 |
| 112 } // namespace skia | 112 } // namespace skia |
| 113 | 113 |
| 114 #endif // SKIA_EXT_BITMAP_PLATFORM_DEVICE_LINUX_H_ | 114 #endif // SKIA_EXT_BITMAP_PLATFORM_DEVICE_LINUX_H_ |
| OLD | NEW |