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

Side by Side Diff: chrome/browser/ui/app_list/app_list_prefs_factory.cc

Issue 1658793002: Update chrome for new prefs location. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/app_list/app_list_prefs_factory.h" 5 #include "chrome/browser/ui/app_list/app_list_prefs_factory.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/prefs/pref_service.h"
10 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
11 #include "chrome/browser/ui/app_list/app_list_prefs.h" 10 #include "chrome/browser/ui/app_list/app_list_prefs.h"
12 #include "components/keyed_service/content/browser_context_dependency_manager.h" 11 #include "components/keyed_service/content/browser_context_dependency_manager.h"
12 #include "components/prefs/pref_service.h"
13 #include "content/public/browser/browser_context.h" 13 #include "content/public/browser/browser_context.h"
14 #include "extensions/browser/extensions_browser_client.h" 14 #include "extensions/browser/extensions_browser_client.h"
15 15
16 namespace app_list { 16 namespace app_list {
17 17
18 // static 18 // static
19 AppListPrefs* AppListPrefsFactory::GetForBrowserContext( 19 AppListPrefs* AppListPrefsFactory::GetForBrowserContext(
20 content::BrowserContext* context) { 20 content::BrowserContext* context) {
21 return static_cast<AppListPrefs*>( 21 return static_cast<AppListPrefs*>(
22 GetInstance()->GetServiceForBrowserContext(context, true)); 22 GetInstance()->GetServiceForBrowserContext(context, true));
(...skipping 24 matching lines...) Expand all
47 return AppListPrefs::Create(Profile::FromBrowserContext(context)->GetPrefs()); 47 return AppListPrefs::Create(Profile::FromBrowserContext(context)->GetPrefs());
48 } 48 }
49 49
50 content::BrowserContext* AppListPrefsFactory::GetBrowserContextToUse( 50 content::BrowserContext* AppListPrefsFactory::GetBrowserContextToUse(
51 content::BrowserContext* context) const { 51 content::BrowserContext* context) const {
52 return extensions::ExtensionsBrowserClient::Get()->GetOriginalContext( 52 return extensions::ExtensionsBrowserClient::Get()->GetOriginalContext(
53 context); 53 context);
54 } 54 }
55 55
56 } // namespace app_list 56 } // namespace app_list
OLDNEW
« no previous file with comments | « chrome/browser/ui/app_list/app_list_prefs.cc ('k') | chrome/browser/ui/app_list/app_list_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698