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

Side by Side Diff: chrome/browser/favicon/chrome_fallback_icon_client.cc

Issue 996253002: [Fallback Icons] Refactor FallbackIconService to be a BrowserContext-level singleton (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sync and reverting small unneeded change. Created 5 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
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/browser/favicon/chrome_fallback_icon_client.h"
6
7 #include "chrome/browser/favicon/fallback_icon_service_factory.h"
8 #include "grit/platform_locale_settings.h"
9 #include "ui/base/l10n/l10n_util.h"
10
11 ChromeFallbackIconClient::ChromeFallbackIconClient(Profile* profile)
12 : profile_(profile) {
13 #if defined(OS_CHROMEOS)
14 font_list_.push_back("Noto Sans");
15 #elif defined(OS_IOS)
16 font_list_.push_back("Helvetica Neue");
17 #else
18 font_list_.push_back(l10n_util::GetStringUTF8(IDS_SANS_SERIF_FONT_FAMILY));
19 #endif
20 }
21
22 ChromeFallbackIconClient::~ChromeFallbackIconClient() {
23 }
24
25 favicon_base::FallbackIconService*
26 ChromeFallbackIconClient::GetFallbackIconService() {
27 return FallbackIconServiceFactory::GetForProfile(
sdefresne 2015/03/16 09:11:29 As I'll say later, please remove this method.
huangs 2015/03/16 22:06:10 Done.
28 profile_, ServiceAccessType::EXPLICIT_ACCESS);
29 }
30
31 const std::vector<std::string>& ChromeFallbackIconClient::GetFontNameList() {
32 return font_list_;
33 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698