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

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

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_win.h ('k') | skia/ext/vector_platform_device_cairo_linux.h » ('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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #include "skia/ext/platform_device_win.h" 5 #include "skia/ext/platform_device_win.h"
6 6
7 #include "skia/ext/skia_utils_win.h" 7 #include "skia/ext/skia_utils_win.h"
8 #include "third_party/skia/include/core/SkMatrix.h" 8 #include "third_party/skia/include/core/SkMatrix.h"
9 #include "third_party/skia/include/core/SkPath.h" 9 #include "third_party/skia/include/core/SkPath.h"
10 #include "third_party/skia/include/core/SkRegion.h" 10 #include "third_party/skia/include/core/SkRegion.h"
11 #include "third_party/skia/include/core/SkUtils.h" 11 #include "third_party/skia/include/core/SkUtils.h"
12 12
13 namespace skia { 13 namespace skia {
14 14
15 PlatformDevice::PlatformDevice(const SkBitmap& bitmap) 15 PlatformDevice::PlatformDevice(const SkBitmap& bitmap)
16 : SkDevice(NULL, bitmap, /*isForLayer=*/false) { 16 : SkDevice(NULL, bitmap, /*isForLayer=*/false) {
17 } 17 }
18 18
19 void PlatformDevice::EndPlatformPaint() {
20 // We don't clear the DC here since it will be likely to be used again.
21 // Flushing will be done in onAccessBitmap.
22 }
23
19 // static 24 // static
20 void PlatformDevice::InitializeDC(HDC context) { 25 void PlatformDevice::InitializeDC(HDC context) {
21 // Enables world transformation. 26 // Enables world transformation.
22 // If the GM_ADVANCED graphics mode is set, GDI always draws arcs in the 27 // If the GM_ADVANCED graphics mode is set, GDI always draws arcs in the
23 // counterclockwise direction in logical space. This is equivalent to the 28 // counterclockwise direction in logical space. This is equivalent to the
24 // statement that, in the GM_ADVANCED graphics mode, both arc control points 29 // statement that, in the GM_ADVANCED graphics mode, both arc control points
25 // and arcs themselves fully respect the device context's world-to-device 30 // and arcs themselves fully respect the device context's world-to-device
26 // transformation. 31 // transformation.
27 BOOL res = SetGraphicsMode(context, GM_ADVANCED); 32 BOOL res = SetGraphicsMode(context, GM_ADVANCED);
28 SkASSERT(res != 0); 33 SkASSERT(res != 0);
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 hrgn = PathToRegion(context); 224 hrgn = PathToRegion(context);
220 } 225 }
221 int result = SelectClipRgn(context, hrgn); 226 int result = SelectClipRgn(context, hrgn);
222 SkASSERT(result != ERROR); 227 SkASSERT(result != ERROR);
223 result = DeleteObject(hrgn); 228 result = DeleteObject(hrgn);
224 SkASSERT(result != 0); 229 SkASSERT(result != 0);
225 } 230 }
226 231
227 } // namespace skia 232 } // namespace skia
228 233
OLDNEW
« no previous file with comments | « skia/ext/platform_device_win.h ('k') | skia/ext/vector_platform_device_cairo_linux.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698