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

Side by Side Diff: chrome/browser/ntp_background_util.h

Issue 9562038: ui/gfx: Make gfx::Canvas inherit from gfx::CanvasSkia. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: more fixes Created 8 years, 9 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
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_BROWSER_NTP_BACKGROUND_UTIL_H_ 5 #ifndef CHROME_BROWSER_NTP_BACKGROUND_UTIL_H_
6 #define CHROME_BROWSER_NTP_BACKGROUND_UTIL_H_ 6 #define CHROME_BROWSER_NTP_BACKGROUND_UTIL_H_
7 #pragma once 7 #pragma once
8 8
9 namespace gfx { 9 namespace gfx {
10 class Canvas; 10 class CanvasSkia;
11 class Rect; 11 class Rect;
12 } 12 }
13 13
14 namespace ui { 14 namespace ui {
15 class ThemeProvider; 15 class ThemeProvider;
16 } 16 }
17 17
18 class NtpBackgroundUtil { 18 class NtpBackgroundUtil {
19 public: 19 public:
20 // Paints the NTP background on |canvas|. |area| is the area of the canvas 20 // Paints the NTP background on |canvas|. |area| is the area of the canvas
21 // that gets painted and also serves as the origin of the image (for top- 21 // that gets painted and also serves as the origin of the image (for top-
22 // aligned images). |tab_contents_height| is necessary for correctly painting 22 // aligned images). |tab_contents_height| is necessary for correctly painting
23 // bottom-aligned images since then the origin is the bottom of the web page. 23 // bottom-aligned images since then the origin is the bottom of the web page.
24 static void PaintBackgroundDetachedMode( 24 static void PaintBackgroundDetachedMode(ui::ThemeProvider* tp,
25 ui::ThemeProvider* tp, gfx::Canvas* canvas, 25 gfx::CanvasSkia* canvas,
26 const gfx::Rect& area, int tab_contents_height); 26 const gfx::Rect& area,
27 int tab_contents_height);
27 28
28 private: 29 private:
29 NtpBackgroundUtil() {} 30 NtpBackgroundUtil() {}
30 }; 31 };
31 32
32 #endif // CHROME_BROWSER_NTP_BACKGROUND_UTIL_H_ 33 #endif // CHROME_BROWSER_NTP_BACKGROUND_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698