Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(415)

Side by Side Diff: skia/ext/platform_device_win.h

Issue 6691067: Fixed a few styles issues in skia::PlatformDevice. Made function names consistent. Added Begin/En... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « skia/ext/platform_device_mac.cc ('k') | skia/ext/platform_device_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_PLATFORM_DEVICE_WIN_H_ 5 #ifndef SKIA_EXT_PLATFORM_DEVICE_WIN_H_
6 #define SKIA_EXT_PLATFORM_DEVICE_WIN_H_ 6 #define SKIA_EXT_PLATFORM_DEVICE_WIN_H_
7 #pragma once 7 #pragma once
8 8
9 #include <windows.h> 9 #include <windows.h>
10 10
(...skipping 12 matching lines...) Expand all
23 // to. It also provides functionality to play well with GDI drawing functions. 23 // to. It also provides functionality to play well with GDI drawing functions.
24 // This class is abstract and must be subclassed. It provides the basic 24 // This class is abstract and must be subclassed. It provides the basic
25 // interface to implement it either with or without a bitmap backend. 25 // interface to implement it either with or without a bitmap backend.
26 class SK_API PlatformDevice : public SkDevice { 26 class SK_API PlatformDevice : public SkDevice {
27 public: 27 public:
28 typedef HDC PlatformSurface; 28 typedef HDC PlatformSurface;
29 29
30 // The DC that corresponds to the bitmap, used for GDI operations drawing 30 // The DC that corresponds to the bitmap, used for GDI operations drawing
31 // into the bitmap. This is possibly heavyweight, so it should be existant 31 // into the bitmap. This is possibly heavyweight, so it should be existant
32 // only during one pass of rendering. 32 // only during one pass of rendering.
33 virtual HDC beginPlatformPaint() = 0; 33 virtual PlatformSurface BeginPlatformPaint() = 0;
34 34
35 // Finish a previous call to beginPlatformPaint. 35 // Finish a previous call to beginPlatformPaint.
36 virtual void endPlatformPaint() { } 36 virtual void EndPlatformPaint();
37 37
38 // Draws to the given screen DC, if the bitmap DC doesn't exist, this will 38 // Draws to the given screen DC, if the bitmap DC doesn't exist, this will
39 // temporarily create it. However, if you have created the bitmap DC, it will 39 // temporarily create it. However, if you have created the bitmap DC, it will
40 // be more efficient if you don't free it until after this call so it doesn't 40 // be more efficient if you don't free it until after this call so it doesn't
41 // have to be created twice. If src_rect is null, then the entirety of the 41 // have to be created twice. If src_rect is null, then the entirety of the
42 // source device will be copied. 42 // source device will be copied.
43 virtual void drawToHDC(HDC dc, int x, int y, const RECT* src_rect) = 0; 43 virtual void drawToHDC(HDC dc, int x, int y, const RECT* src_rect) = 0;
44 44
45 // Sets the opacity of each pixel in the specified region to be opaque. 45 // Sets the opacity of each pixel in the specified region to be opaque.
46 virtual void makeOpaque(int x, int y, int width, int height) { } 46 virtual void makeOpaque(int x, int y, int width, int height) { }
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 static void LoadTransformToDC(HDC dc, const SkMatrix& matrix); 78 static void LoadTransformToDC(HDC dc, const SkMatrix& matrix);
79 79
80 // Transforms SkPath's paths into a series of cubic path. 80 // Transforms SkPath's paths into a series of cubic path.
81 static bool SkPathToCubicPaths(CubicPaths* paths, const SkPath& skpath); 81 static bool SkPathToCubicPaths(CubicPaths* paths, const SkPath& skpath);
82 }; 82 };
83 83
84 } // namespace skia 84 } // namespace skia
85 85
86 #endif // SKIA_EXT_PLATFORM_DEVICE_WIN_H_ 86 #endif // SKIA_EXT_PLATFORM_DEVICE_WIN_H_
87 87
OLDNEW
« no previous file with comments | « skia/ext/platform_device_mac.cc ('k') | skia/ext/platform_device_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698