OLD | NEW |
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 "chrome/browser/ui/gtk/tabs/tab_renderer_gtk.h" | 5 #include "chrome/browser/ui/gtk/tabs/tab_renderer_gtk.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 #include "grit/generated_resources.h" | 24 #include "grit/generated_resources.h" |
25 #include "grit/theme_resources.h" | 25 #include "grit/theme_resources.h" |
26 #include "grit/theme_resources_standard.h" | 26 #include "grit/theme_resources_standard.h" |
27 #include "grit/ui_resources.h" | 27 #include "grit/ui_resources.h" |
28 #include "ui/base/animation/slide_animation.h" | 28 #include "ui/base/animation/slide_animation.h" |
29 #include "ui/base/animation/throb_animation.h" | 29 #include "ui/base/animation/throb_animation.h" |
30 #include "ui/base/l10n/l10n_util.h" | 30 #include "ui/base/l10n/l10n_util.h" |
31 #include "ui/base/resource/resource_bundle.h" | 31 #include "ui/base/resource/resource_bundle.h" |
32 #include "ui/gfx/canvas_skia_paint.h" | 32 #include "ui/gfx/canvas_skia_paint.h" |
33 #include "ui/gfx/favicon_size.h" | 33 #include "ui/gfx/favicon_size.h" |
34 #include "ui/gfx/platform_font_gtk.h" | 34 #include "ui/gfx/platform_font_pango.h" |
35 #include "ui/gfx/skbitmap_operations.h" | 35 #include "ui/gfx/skbitmap_operations.h" |
36 | 36 |
37 #if !GTK_CHECK_VERSION(2, 22, 0) | 37 #if !GTK_CHECK_VERSION(2, 22, 0) |
38 #define gtk_button_get_event_window(button) button->event_window | 38 #define gtk_button_get_event_window(button) button->event_window |
39 #endif // Gtk+ >= 2.22 | 39 #endif // Gtk+ >= 2.22 |
40 | 40 |
41 namespace { | 41 namespace { |
42 | 42 |
43 const int kFontPixelSize = 12; | 43 const int kFontPixelSize = 12; |
44 const int kLeftPadding = 16; | 44 const int kLeftPadding = 16; |
(...skipping 1043 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1088 | 1088 |
1089 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); | 1089 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); |
1090 const gfx::Font& base_font = rb.GetFont(ResourceBundle::BaseFont); | 1090 const gfx::Font& base_font = rb.GetFont(ResourceBundle::BaseFont); |
1091 title_font_ = new gfx::Font(base_font.GetFontName(), kFontPixelSize); | 1091 title_font_ = new gfx::Font(base_font.GetFontName(), kFontPixelSize); |
1092 title_font_height_ = title_font_->GetHeight(); | 1092 title_font_height_ = title_font_->GetHeight(); |
1093 | 1093 |
1094 crashed_favicon = rb.GetBitmapNamed(IDR_SAD_FAVICON); | 1094 crashed_favicon = rb.GetBitmapNamed(IDR_SAD_FAVICON); |
1095 | 1095 |
1096 initialized_ = true; | 1096 initialized_ = true; |
1097 } | 1097 } |
OLD | NEW |