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

Side by Side Diff: base/gfx/native_theme.cc

Issue 65012: Move skia to DEPS, and put it in third_party. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 7 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 | « base/gfx/native_theme.h ('k') | base/gfx/png_decoder.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) 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 "base/gfx/native_theme.h" 5 #include "base/gfx/native_theme.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 #include <uxtheme.h> 8 #include <uxtheme.h>
9 #include <vsstyle.h> 9 #include <vsstyle.h>
10 #include <vssym32.h> 10 #include <vssym32.h>
11 11
12 #include "base/gfx/gdi_util.h" 12 #include "base/gfx/gdi_util.h"
13 #include "base/gfx/rect.h" 13 #include "base/gfx/rect.h"
14 #include "base/logging.h" 14 #include "base/logging.h"
15 #include "base/scoped_handle.h" 15 #include "base/scoped_handle.h"
16 #include "skia/ext/platform_canvas.h" 16 #include "skia/ext/platform_canvas.h"
17 #include "skia/ext/skia_utils_win.h" 17 #include "skia/ext/skia_utils_win.h"
18 #include "skia/include/SkShader.h" 18 #include "third_party/skia/include/core/SkShader.h"
19 19
20 namespace { 20 namespace {
21 21
22 void SetCheckerboardShader(SkPaint* paint, const RECT& align_rect) { 22 void SetCheckerboardShader(SkPaint* paint, const RECT& align_rect) {
23 // Create a 2x2 checkerboard pattern using the 3D face and highlight colors. 23 // Create a 2x2 checkerboard pattern using the 3D face and highlight colors.
24 SkColor face = skia::COLORREFToSkColor(GetSysColor(COLOR_3DFACE)); 24 SkColor face = skia::COLORREFToSkColor(GetSysColor(COLOR_3DFACE));
25 SkColor highlight = skia::COLORREFToSkColor(GetSysColor(COLOR_3DHILIGHT)); 25 SkColor highlight = skia::COLORREFToSkColor(GetSysColor(COLOR_3DHILIGHT));
26 SkColor buffer[] = { face, highlight, highlight, face }; 26 SkColor buffer[] = { face, highlight, highlight, face };
27 // Confusing bit: we first create a temporary bitmap with our desired pattern, 27 // Confusing bit: we first create a temporary bitmap with our desired pattern,
28 // then copy it to another bitmap. The temporary bitmap doesn't take 28 // then copy it to another bitmap. The temporary bitmap doesn't take
(...skipping 672 matching lines...) Expand 10 before | Expand all | Expand 10 after
701 handle = open_theme_(NULL, L"Window"); 701 handle = open_theme_(NULL, L"Window");
702 break; 702 break;
703 default: 703 default:
704 NOTREACHED(); 704 NOTREACHED();
705 } 705 }
706 theme_handles_[theme_name] = handle; 706 theme_handles_[theme_name] = handle;
707 return handle; 707 return handle;
708 } 708 }
709 709
710 } // namespace gfx 710 } // namespace gfx
OLDNEW
« no previous file with comments | « base/gfx/native_theme.h ('k') | base/gfx/png_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698