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

Side by Side Diff: ui/gfx/canvas_direct2d_unittest.cc

Issue 6825055: Include base/win/scoped_comptr.h instead of base/scoped_comptr_win.h. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: revert bad indentation, rebase 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 | « ui/gfx/canvas_direct2d.cc ('k') | no next file » | 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 #include <windows.h> 5 #include <windows.h>
6 #include <uxtheme.h> 6 #include <uxtheme.h>
7 #include <vsstyle.h> 7 #include <vsstyle.h>
8 #include <vssym32.h> 8 #include <vssym32.h>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 ATOM atom = RegisterClassEx(&class_ex); 92 ATOM atom = RegisterClassEx(&class_ex);
93 DCHECK(atom); 93 DCHECK(atom);
94 } 94 }
95 95
96 void UnregisterMyClass() { 96 void UnregisterMyClass() {
97 ::UnregisterClass(kWindowClassName, NULL); 97 ::UnregisterClass(kWindowClassName, NULL);
98 } 98 }
99 99
100 HWND hwnd_; 100 HWND hwnd_;
101 101
102 ScopedComPtr<ID2D1RenderTarget> rt_; 102 base::win::ScopedComPtr<ID2D1RenderTarget> rt_;
103 103
104 DISALLOW_COPY_AND_ASSIGN(TestWindow); 104 DISALLOW_COPY_AND_ASSIGN(TestWindow);
105 }; 105 };
106 106
107 // Loads a png data blob from the data resources associated with this 107 // Loads a png data blob from the data resources associated with this
108 // executable, decodes it and returns a SkBitmap. 108 // executable, decodes it and returns a SkBitmap.
109 SkBitmap LoadBitmapFromResources(int resource_id) { 109 SkBitmap LoadBitmapFromResources(int resource_id) {
110 SkBitmap bitmap; 110 SkBitmap bitmap;
111 111
112 HINSTANCE resource_instance = GetModuleHandle(NULL); 112 HINSTANCE resource_instance = GetModuleHandle(NULL);
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
323 return; 323 return;
324 TestWindow window; 324 TestWindow window;
325 gfx::CanvasDirect2D canvas(window.rt()); 325 gfx::CanvasDirect2D canvas(window.rt());
326 326
327 SkBitmap bitmap = LoadBitmapFromResources(IDR_BITMAP_BRUSH_IMAGE); 327 SkBitmap bitmap = LoadBitmapFromResources(IDR_BITMAP_BRUSH_IMAGE);
328 328
329 canvas.Save(); 329 canvas.Save();
330 canvas.TileImageInt(bitmap, 10, 10, 300, 300); 330 canvas.TileImageInt(bitmap, 10, 10, 300, 300);
331 canvas.Restore(); 331 canvas.Restore();
332 } 332 }
OLDNEW
« no previous file with comments | « ui/gfx/canvas_direct2d.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698