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

Unified Diff: chrome/browser/chromeos/extensions/file_manager/volume_manager_factory.cc

Issue 23892008: Move VolumeManager to c/b/chromeos/file_manager (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
Index: chrome/browser/chromeos/extensions/file_manager/volume_manager_factory.cc
diff --git a/chrome/browser/chromeos/extensions/file_manager/volume_manager_factory.cc b/chrome/browser/chromeos/extensions/file_manager/volume_manager_factory.cc
deleted file mode 100644
index fed982aa9ca7265003a4faf5ac05e7e3ec479f98..0000000000000000000000000000000000000000
--- a/chrome/browser/chromeos/extensions/file_manager/volume_manager_factory.cc
+++ /dev/null
@@ -1,58 +0,0 @@
-// Copyright 2013 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/chromeos/extensions/file_manager/volume_manager_factory.h"
-
-#include "base/basictypes.h"
-#include "base/memory/singleton.h"
-#include "chrome/browser/chromeos/extensions/file_manager/volume_manager.h"
-#include "chrome/browser/profiles/incognito_helpers.h"
-#include "chrome/browser/profiles/profile.h"
-#include "chromeos/disks/disk_mount_manager.h"
-#include "components/browser_context_keyed_service/browser_context_dependency_manager.h"
-
-namespace file_manager {
-
-VolumeManager* VolumeManagerFactory::Get(content::BrowserContext* context) {
- return static_cast<VolumeManager*>(
- GetInstance()->GetServiceForBrowserContext(context, true));
-}
-
-VolumeManagerFactory* VolumeManagerFactory::GetInstance() {
- return Singleton<VolumeManagerFactory>::get();
-}
-
-content::BrowserContext* VolumeManagerFactory::GetBrowserContextToUse(
- content::BrowserContext* context) const {
- // Explicitly allow this manager in guest login mode.
- return chrome::GetBrowserContextOwnInstanceInIncognito(context);
-}
-
-bool VolumeManagerFactory::ServiceIsCreatedWithBrowserContext() const {
- return true;
-}
-
-bool VolumeManagerFactory::ServiceIsNULLWhileTesting() const {
- return true;
-}
-
-BrowserContextKeyedService* VolumeManagerFactory::BuildServiceInstanceFor(
- content::BrowserContext* profile) const {
- VolumeManager* instance =
- new VolumeManager(Profile::FromBrowserContext(profile),
- chromeos::disks::DiskMountManager::GetInstance());
- instance->Initialize();
- return instance;
-}
-
-VolumeManagerFactory::VolumeManagerFactory()
- : BrowserContextKeyedServiceFactory(
- "VolumeManagerFactory",
- BrowserContextDependencyManager::GetInstance()) {
-}
-
-VolumeManagerFactory::~VolumeManagerFactory() {
-}
-
-} // namespace file_manager

Powered by Google App Engine
This is Rietveld 408576698