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

Side by Side Diff: chrome/browser/gtk/sad_tab_gtk.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 | « chrome/browser/gtk/menu_gtk.cc ('k') | chrome/browser/gtk/tabs/tab_renderer_gtk.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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 "chrome/browser/gtk/sad_tab_gtk.h" 5 #include "chrome/browser/gtk/sad_tab_gtk.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "app/gfx/chrome_canvas.h" 9 #include "app/gfx/chrome_canvas.h"
10 #include "app/gfx/chrome_font.h" 10 #include "app/gfx/chrome_font.h"
11 #include "app/l10n_util.h" 11 #include "app/l10n_util.h"
12 #include "app/resource_bundle.h" 12 #include "app/resource_bundle.h"
13 #include "base/gfx/size.h" 13 #include "base/gfx/size.h"
14 #include "base/lazy_instance.h" 14 #include "base/lazy_instance.h"
15 #include "grit/generated_resources.h" 15 #include "grit/generated_resources.h"
16 #include "grit/theme_resources.h" 16 #include "grit/theme_resources.h"
17 #include "skia/ext/skia_utils.h" 17 #include "skia/ext/skia_utils.h"
18 #include "skia/include/SkGradientShader.h" 18 #include "third_party/skia/include/effects/SkGradientShader.h"
19 19
20 namespace { 20 namespace {
21 21
22 // The y offset from the center at which to paint the icon. 22 // The y offset from the center at which to paint the icon.
23 const int kSadTabOffset = -64; 23 const int kSadTabOffset = -64;
24 // The spacing between the icon and the title. 24 // The spacing between the icon and the title.
25 const int kIconTitleSpacing = 20; 25 const int kIconTitleSpacing = 20;
26 // The spacing between the title and the message. 26 // The spacing between the title and the message.
27 const int kTitleMessageSpacing = 15; 27 const int kTitleMessageSpacing = 15;
28 const SkColor kTitleTextColor = SK_ColorWHITE; 28 const SkColor kTitleTextColor = SK_ColorWHITE;
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 int icon_y = ((event->height - icon_height) / 2) + kSadTabOffset; 143 int icon_y = ((event->height - icon_height) / 2) + kSadTabOffset;
144 icon_bounds_.SetRect(icon_x, icon_y, icon_width, icon_height); 144 icon_bounds_.SetRect(icon_x, icon_y, icon_width, icon_height);
145 145
146 title_y_ = 146 title_y_ =
147 icon_bounds_.bottom() + kIconTitleSpacing; 147 icon_bounds_.bottom() + kIconTitleSpacing;
148 int title_height = sad_tab_constants.title_font.height(); 148 int title_height = sad_tab_constants.title_font.height();
149 message_y_ = 149 message_y_ =
150 title_y_ + title_height + kTitleMessageSpacing; 150 title_y_ + title_height + kTitleMessageSpacing;
151 return TRUE; 151 return TRUE;
152 } 152 }
OLDNEW
« no previous file with comments | « chrome/browser/gtk/menu_gtk.cc ('k') | chrome/browser/gtk/tabs/tab_renderer_gtk.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698