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

Unified Diff: chrome/browser/ui/views/download/download_danger_prompt_views.cc

Issue 152343006: Clean-up: Replaces obsolete Font/FontList methods. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Synced. Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/download/download_danger_prompt_views.cc
diff --git a/chrome/browser/ui/views/download/download_danger_prompt_views.cc b/chrome/browser/ui/views/download/download_danger_prompt_views.cc
index 8f01728b6a6e044a1561526e4bae046e3bf635a3..83f917a8212aaf233e753df331f17e6634395407 100644
--- a/chrome/browser/ui/views/download/download_danger_prompt_views.cc
+++ b/chrome/browser/ui/views/download/download_danger_prompt_views.cc
@@ -16,6 +16,7 @@
#include "grit/chromium_strings.h"
#include "grit/generated_resources.h"
#include "ui/base/l10n/l10n_util.h"
+#include "ui/base/resource/resource_bundle.h"
#include "ui/views/controls/button/label_button.h"
#include "ui/views/controls/label.h"
#include "ui/views/layout/grid_layout.h"
@@ -110,14 +111,13 @@ DownloadDangerPromptViews::DownloadDangerPromptViews(
const base::string16 message_lead = GetMessageLead();
if (!message_lead.empty()) {
- views::Label* message_lead_label = new views::Label(message_lead);
+ ui::ResourceBundle* rb = &ui::ResourceBundle::GetSharedInstance();
+ views::Label* message_lead_label = new views::Label(
+ message_lead, rb->GetFontList(ui::ResourceBundle::BoldFont));
message_lead_label->SetMultiLine(true);
message_lead_label->SetHorizontalAlignment(gfx::ALIGN_LEFT);
message_lead_label->SetAllowCharacterBreak(true);
- gfx::FontList font_list(gfx::Font().DeriveFont(0, gfx::Font::BOLD));
- message_lead_label->SetFontList(font_list);
-
layout->StartRow(0, 0);
layout->AddView(message_lead_label);
« no previous file with comments | « chrome/browser/ui/views/accessibility/invert_bubble_view.cc ('k') | chrome/browser/ui/views/first_run_bubble.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698