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

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

Issue 14110: Move the "platform" wrappers in skia/ext to the skia namespace. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 12 years 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.h ('k') | skia/ext/platform_device_win.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/bitmap_platform_device_mac.h" 5 #include "skia/ext/bitmap_platform_device_mac.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "skia/ext/skia_utils_mac.h" 8 #include "skia/ext/skia_utils_mac.h"
9 #include "SkMatrix.h" 9 #include "SkMatrix.h"
10 #include "SkPath.h" 10 #include "SkPath.h"
11 #include "SkUtils.h" 11 #include "SkUtils.h"
12 12
13 namespace gfx { 13 namespace skia {
14
15 // TODO(brettw) remove this when the gfx namespaces are all removed.
16 using namespace gfx;
14 17
15 namespace { 18 namespace {
16 19
17 // Constrains position and size to fit within available_size. 20 // Constrains position and size to fit within available_size.
18 bool constrain(int available_size, int* position, int *size) { 21 bool constrain(int available_size, int* position, int *size) {
19 if (*position < 0) { 22 if (*position < 0) {
20 *size += *position; 23 *size += *position;
21 *position = 0; 24 *position = 0;
22 } 25 }
23 if (*size > 0 && *position < available_size) { 26 if (*size > 0 && *position < available_size) {
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 // Clip. Note that windows clipping regions are not affected by the 153 // Clip. Note that windows clipping regions are not affected by the
151 // transform so apply it manually. 154 // transform so apply it manually.
152 path.transform(transformation); 155 path.transform(transformation);
153 // TODO(playmobil): Implement. 156 // TODO(playmobil): Implement.
154 NOTREACHED(); 157 NOTREACHED();
155 // LoadPathToDC(context, path); 158 // LoadPathToDC(context, path);
156 // hrgn = PathToRegion(context); 159 // hrgn = PathToRegion(context);
157 } 160 }
158 } 161 }
159 162
160 } // namespace gfx 163 } // namespace skia
161 164
OLDNEW
« no previous file with comments | « skia/ext/platform_device_mac.h ('k') | skia/ext/platform_device_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698