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

Unified Diff: chrome/browser/plugin_prefs_factory.cc

Issue 10933044: Move chrome/browser/plugin_* to chrome/browser/plugins/ (Closed) Base URL: http://git.chromium.org/chromium/src.git@remove_plugin_group
Patch Set: . Created 8 years, 3 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
« no previous file with comments | « chrome/browser/plugin_prefs_factory.h ('k') | chrome/browser/plugin_prefs_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/plugin_prefs_factory.cc
diff --git a/chrome/browser/plugin_prefs_factory.cc b/chrome/browser/plugin_prefs_factory.cc
deleted file mode 100644
index 75b7f26831ef5e2eea633e176f829a3205b009de..0000000000000000000000000000000000000000
--- a/chrome/browser/plugin_prefs_factory.cc
+++ /dev/null
@@ -1,85 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "chrome/browser/plugin_prefs_factory.h"
-
-#include "base/path_service.h"
-#include "chrome/browser/plugin_prefs.h"
-#include "chrome/browser/prefs/pref_service.h"
-#include "chrome/browser/profiles/profile.h"
-#include "chrome/browser/profiles/profile_dependency_manager.h"
-#include "chrome/browser/profiles/profile_keyed_service.h"
-#include "chrome/common/chrome_paths.h"
-#include "chrome/common/pref_names.h"
-
-// static
-PluginPrefsFactory* PluginPrefsFactory::GetInstance() {
- return Singleton<PluginPrefsFactory>::get();
-}
-
-// static
-scoped_refptr<PluginPrefs> PluginPrefsFactory::GetPrefsForProfile(
- Profile* profile) {
- return static_cast<PluginPrefs*>(
- GetInstance()->GetServiceForProfile(profile, true).get());
-}
-
-// static
-scoped_refptr<RefcountedProfileKeyedService>
-PluginPrefsFactory::CreateForTestingProfile(Profile* profile) {
- return static_cast<PluginPrefs*>(
- GetInstance()->BuildServiceInstanceFor(profile).get());
-}
-
-PluginPrefsFactory::PluginPrefsFactory()
- : RefcountedProfileKeyedServiceFactory(
- "PluginPrefs", ProfileDependencyManager::GetInstance()) {
-}
-
-PluginPrefsFactory::~PluginPrefsFactory() {}
-
-scoped_refptr<RefcountedProfileKeyedService>
-PluginPrefsFactory::BuildServiceInstanceFor(Profile* profile) const {
- scoped_refptr<PluginPrefs> plugin_prefs(new PluginPrefs());
- plugin_prefs->set_profile(profile->GetOriginalProfile());
- plugin_prefs->SetPrefs(profile->GetPrefs());
- return plugin_prefs;
-}
-
-void PluginPrefsFactory::RegisterUserPrefs(PrefService* prefs) {
- FilePath internal_dir;
- PathService::Get(chrome::DIR_INTERNAL_PLUGINS, &internal_dir);
- prefs->RegisterFilePathPref(prefs::kPluginsLastInternalDirectory,
- internal_dir,
- PrefService::UNSYNCABLE_PREF);
- prefs->RegisterBooleanPref(prefs::kPluginsEnabledInternalPDF,
- false,
- PrefService::UNSYNCABLE_PREF);
- prefs->RegisterBooleanPref(prefs::kPluginsEnabledNaCl,
- false,
- PrefService::UNSYNCABLE_PREF);
- prefs->RegisterBooleanPref(prefs::kPluginsMigratedToPepperFlash,
- false,
- PrefService::UNSYNCABLE_PREF);
- prefs->RegisterListPref(prefs::kPluginsPluginsList,
- PrefService::UNSYNCABLE_PREF);
- prefs->RegisterListPref(prefs::kPluginsDisabledPlugins,
- PrefService::UNSYNCABLE_PREF);
- prefs->RegisterListPref(prefs::kPluginsDisabledPluginsExceptions,
- PrefService::UNSYNCABLE_PREF);
- prefs->RegisterListPref(prefs::kPluginsEnabledPlugins,
- PrefService::UNSYNCABLE_PREF);
-}
-
-bool PluginPrefsFactory::ServiceRedirectedInIncognito() const {
- return true;
-}
-
-bool PluginPrefsFactory::ServiceIsNULLWhileTesting() const {
- return true;
-}
-
-bool PluginPrefsFactory::ServiceIsCreatedWithProfile() const {
- return true;
-}
« no previous file with comments | « chrome/browser/plugin_prefs_factory.h ('k') | chrome/browser/plugin_prefs_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698