OLD | NEW |
| (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/permissions/permission_context_factory_base.h" | |
6 | |
7 #include "chrome/browser/content_settings/host_content_settings_map_factory.h" | |
8 #include "chrome/browser/profiles/incognito_helpers.h" | |
9 #include "components/keyed_service/content/browser_context_dependency_manager.h" | |
10 #include "content/public/browser/browser_context.h" | |
11 | |
12 PermissionContextFactoryBase::PermissionContextFactoryBase( | |
13 const char* name, | |
14 BrowserContextDependencyManager* manager) | |
15 : BrowserContextKeyedServiceFactory(name, manager) { | |
16 DependsOn(HostContentSettingsMapFactory::GetInstance()); | |
17 } | |
18 | |
19 PermissionContextFactoryBase::~PermissionContextFactoryBase() { | |
20 } | |
21 | |
22 content::BrowserContext* | |
23 PermissionContextFactoryBase::GetBrowserContextToUse( | |
24 content::BrowserContext* context) const { | |
25 return chrome::GetBrowserContextOwnInstanceInIncognito(context); | |
26 } | |
OLD | NEW |