| OLD | NEW | 
|---|
| 1 // Copyright (c) 2012 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 #include "chrome/browser/ui/views/first_run_bubble.h" | 5 #include "chrome/browser/ui/views/first_run_bubble.h" | 
| 6 | 6 | 
| 7 #include "chrome/browser/first_run/first_run.h" | 7 #include "chrome/browser/first_run/first_run.h" | 
| 8 #include "chrome/browser/search_engines/template_url_service_factory.h" | 8 #include "chrome/browser/search_engines/template_url_service_factory.h" | 
| 9 #include "chrome/browser/ui/browser.h" | 9 #include "chrome/browser/ui/browser.h" | 
| 10 #include "chrome/browser/ui/chrome_pages.h" | 10 #include "chrome/browser/ui/chrome_pages.h" | 
| (...skipping 30 matching lines...) Expand all  Loading... | 
| 41   ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); | 41   ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); | 
| 42   const gfx::FontList& original_font_list = | 42   const gfx::FontList& original_font_list = | 
| 43       rb.GetFontList(ui::ResourceBundle::MediumFont); | 43       rb.GetFontList(ui::ResourceBundle::MediumFont); | 
| 44 | 44 | 
| 45   const base::string16 search_engine_name = browser_ ? | 45   const base::string16 search_engine_name = browser_ ? | 
| 46       GetDefaultSearchEngineName( | 46       GetDefaultSearchEngineName( | 
| 47           TemplateURLServiceFactory::GetForProfile(browser_->profile())) : | 47           TemplateURLServiceFactory::GetForProfile(browser_->profile())) : | 
| 48       base::string16(); | 48       base::string16(); | 
| 49   views::Label* title = new views::Label( | 49   views::Label* title = new views::Label( | 
| 50       l10n_util::GetStringFUTF16(IDS_FR_BUBBLE_TITLE, search_engine_name), | 50       l10n_util::GetStringFUTF16(IDS_FR_BUBBLE_TITLE, search_engine_name), | 
| 51       original_font_list.Derive(2, gfx::Font::BOLD)); | 51       original_font_list.Derive(2, gfx::Font::NORMAL, gfx::Font::Weight::BOLD)); | 
| 52 | 52 | 
| 53   views::Link* change = | 53   views::Link* change = | 
| 54       new views::Link(l10n_util::GetStringUTF16(IDS_FR_BUBBLE_CHANGE)); | 54       new views::Link(l10n_util::GetStringUTF16(IDS_FR_BUBBLE_CHANGE)); | 
| 55   change->SetFontList(original_font_list); | 55   change->SetFontList(original_font_list); | 
| 56   change->set_listener(this); | 56   change->set_listener(this); | 
| 57 | 57 | 
| 58   views::Label* subtext = | 58   views::Label* subtext = | 
| 59       new views::Label(l10n_util::GetStringUTF16(IDS_FR_BUBBLE_SUBTEXT), | 59       new views::Label(l10n_util::GetStringUTF16(IDS_FR_BUBBLE_SUBTEXT), | 
| 60                        original_font_list); | 60                        original_font_list); | 
| 61 | 61 | 
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 134 | 134 | 
| 135 void FirstRunBubble::FirstRunBubbleCloser::CloseBubble() { | 135 void FirstRunBubble::FirstRunBubbleCloser::CloseBubble() { | 
| 136   if (!event_monitor_) | 136   if (!event_monitor_) | 
| 137     return; | 137     return; | 
| 138 | 138 | 
| 139   event_monitor_.reset(); | 139   event_monitor_.reset(); | 
| 140   DCHECK(bubble_); | 140   DCHECK(bubble_); | 
| 141   bubble_->GetWidget()->Close(); | 141   bubble_->GetWidget()->Close(); | 
| 142   bubble_ = nullptr; | 142   bubble_ = nullptr; | 
| 143 } | 143 } | 
| OLD | NEW | 
|---|