| Index: skia/ext/bitmap_platform_device_win.h
|
| ===================================================================
|
| --- skia/ext/bitmap_platform_device_win.h (revision 96545)
|
| +++ skia/ext/bitmap_platform_device_win.h (working copy)
|
| @@ -7,7 +7,8 @@
|
| #pragma once
|
|
|
| #include "base/basictypes.h"
|
| -#include "skia/ext/platform_device_win.h"
|
| +#include "base/compiler_specific.h"
|
| +#include "skia/ext/platform_device.h"
|
|
|
| namespace skia {
|
|
|
| @@ -25,7 +26,7 @@
|
| // For us, that other bitmap will become invalid as soon as the device becomes
|
| // invalid, which may lead to subtle bugs. Therefore, DO NOT ASSIGN THE
|
| // DEVICE'S PIXEL DATA TO ANOTHER BITMAP, make sure you copy instead.
|
| -class SK_API BitmapPlatformDevice : public PlatformDevice {
|
| +class SK_API BitmapPlatformDevice : public PlatformDevice, public SkDevice {
|
| public:
|
| // Factory function. The screen DC is used to create the bitmap, and will not
|
| // be stored beyond this function. is_opaque should be set if the caller
|
| @@ -34,16 +35,11 @@
|
| // The shared_section parameter is optional (pass NULL for default behavior).
|
| // If shared_section is non-null, then it must be a handle to a file-mapping
|
| // object returned by CreateFileMapping. See CreateDIBSection for details.
|
| - static BitmapPlatformDevice* create(HDC screen_dc,
|
| - int width,
|
| - int height,
|
| - bool is_opaque,
|
| - HANDLE shared_section);
|
| + static BitmapPlatformDevice* create(HDC screen_dc, int width, int height,
|
| + bool is_opaque, HANDLE shared_section);
|
|
|
| // This version is the same as above but will get the screen DC itself.
|
| - static BitmapPlatformDevice* create(int width,
|
| - int height,
|
| - bool is_opaque,
|
| + static BitmapPlatformDevice* create(int width, int height, bool is_opaque,
|
| HANDLE shared_section);
|
|
|
| virtual ~BitmapPlatformDevice();
|
| @@ -51,26 +47,27 @@
|
| // PlatformDevice overrides
|
| // Retrieves the bitmap DC, which is the memory DC for our bitmap data. The
|
| // bitmap DC is lazy created.
|
| - virtual PlatformSurface BeginPlatformPaint();
|
| - virtual void EndPlatformPaint();
|
| + virtual PlatformSurface BeginPlatformPaint() OVERRIDE;
|
| + virtual void EndPlatformPaint() OVERRIDE;
|
|
|
| - virtual void DrawToNativeContext(HDC dc, int x, int y, const RECT* src_rect);
|
| - virtual void MakeOpaque(int x, int y, int width, int height);
|
| + virtual void DrawToNativeContext(HDC dc, int x, int y,
|
| + const RECT* src_rect) OVERRIDE;
|
| + virtual void MakeOpaque(int x, int y, int width, int height) OVERRIDE;
|
|
|
| // Loads the given transform and clipping region into the HDC. This is
|
| // overridden from SkDevice.
|
| virtual void setMatrixClip(const SkMatrix& transform, const SkRegion& region,
|
| - const SkClipStack&);
|
| + const SkClipStack&) OVERRIDE;
|
|
|
| protected:
|
| // Flushes the Windows device context so that the pixel data can be accessed
|
| // directly by Skia. Overridden from SkDevice, this is called when Skia
|
| // starts accessing pixel data.
|
| - virtual void onAccessBitmap(SkBitmap* bitmap);
|
| + virtual void onAccessBitmap(SkBitmap* bitmap) OVERRIDE;
|
|
|
| virtual SkDevice* onCreateCompatibleDevice(SkBitmap::Config, int width,
|
| int height, bool isOpaque,
|
| - Usage usage);
|
| + Usage usage) OVERRIDE;
|
|
|
| private:
|
| // Reference counted data that can be shared between multiple devices. This
|
| @@ -96,4 +93,3 @@
|
| } // namespace skia
|
|
|
| #endif // SKIA_EXT_BITMAP_PLATFORM_DEVICE_WIN_H_
|
| -
|
|
|