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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2450713002: arc: Register ARC content file system (Closed)
Patch Set: Created 4 years, 1 month 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/chrome_content_browser_client.h" 5 #include "chrome/browser/chrome_content_browser_client.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 #include "url/origin.h" 193 #include "url/origin.h"
194 194
195 #if defined(OS_WIN) 195 #if defined(OS_WIN)
196 #include "base/strings/string_tokenizer.h" 196 #include "base/strings/string_tokenizer.h"
197 #include "chrome/browser/chrome_browser_main_win.h" 197 #include "chrome/browser/chrome_browser_main_win.h"
198 #include "sandbox/win/src/sandbox_policy.h" 198 #include "sandbox/win/src/sandbox_policy.h"
199 #elif defined(OS_MACOSX) 199 #elif defined(OS_MACOSX)
200 #include "chrome/browser/chrome_browser_main_mac.h" 200 #include "chrome/browser/chrome_browser_main_mac.h"
201 #elif defined(OS_CHROMEOS) 201 #elif defined(OS_CHROMEOS)
202 #include "chrome/browser/chromeos/arc/arc_auth_service.h" 202 #include "chrome/browser/chromeos/arc/arc_auth_service.h"
203 #include "chrome/browser/chromeos/arc/fileapi/arc_content_file_system_backend_de legate.h"
203 #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h" 204 #include "chrome/browser/chromeos/arc/intent_helper/arc_navigation_throttle.h"
204 #include "chrome/browser/chromeos/attestation/platform_verification_impl.h" 205 #include "chrome/browser/chromeos/attestation/platform_verification_impl.h"
205 #include "chrome/browser/chromeos/chrome_browser_main_chromeos.h" 206 #include "chrome/browser/chromeos/chrome_browser_main_chromeos.h"
206 #include "chrome/browser/chromeos/chrome_interface_factory.h" 207 #include "chrome/browser/chromeos/chrome_interface_factory.h"
207 #include "chrome/browser/chromeos/drive/fileapi/file_system_backend_delegate.h" 208 #include "chrome/browser/chromeos/drive/fileapi/file_system_backend_delegate.h"
208 #include "chrome/browser/chromeos/file_manager/app_id.h" 209 #include "chrome/browser/chromeos/file_manager/app_id.h"
209 #include "chrome/browser/chromeos/file_system_provider/fileapi/backend_delegate. h" 210 #include "chrome/browser/chromeos/file_system_provider/fileapi/backend_delegate. h"
210 #include "chrome/browser/chromeos/fileapi/file_system_backend.h" 211 #include "chrome/browser/chromeos/fileapi/file_system_backend.h"
211 #include "chrome/browser/chromeos/fileapi/mtp_file_system_backend_delegate.h" 212 #include "chrome/browser/chromeos/fileapi/mtp_file_system_backend_delegate.h"
212 #include "chrome/browser/chromeos/login/signin/merge_session_navigation_throttle .h" 213 #include "chrome/browser/chromeos/login/signin/merge_session_navigation_throttle .h"
(...skipping 2534 matching lines...) Expand 10 before | Expand all | Expand 10 after
2747 const base::FilePath& storage_partition_path, 2748 const base::FilePath& storage_partition_path,
2748 ScopedVector<storage::FileSystemBackend>* additional_backends) { 2749 ScopedVector<storage::FileSystemBackend>* additional_backends) {
2749 #if defined(OS_CHROMEOS) 2750 #if defined(OS_CHROMEOS)
2750 storage::ExternalMountPoints* external_mount_points = 2751 storage::ExternalMountPoints* external_mount_points =
2751 content::BrowserContext::GetMountPoints(browser_context); 2752 content::BrowserContext::GetMountPoints(browser_context);
2752 DCHECK(external_mount_points); 2753 DCHECK(external_mount_points);
2753 chromeos::FileSystemBackend* backend = new chromeos::FileSystemBackend( 2754 chromeos::FileSystemBackend* backend = new chromeos::FileSystemBackend(
2754 new drive::FileSystemBackendDelegate, 2755 new drive::FileSystemBackendDelegate,
2755 new chromeos::file_system_provider::BackendDelegate, 2756 new chromeos::file_system_provider::BackendDelegate,
2756 new chromeos::MTPFileSystemBackendDelegate(storage_partition_path), 2757 new chromeos::MTPFileSystemBackendDelegate(storage_partition_path),
2757 external_mount_points, 2758 new arc::ArcContentFileSystemBackendDelegate, external_mount_points,
hidehiko 2016/10/25 16:55:44 I know you follow the existing code, but could you
hashimoto 2016/10/26 05:23:12 Replaced with base::MakeUnique().
2758 storage::ExternalMountPoints::GetSystemInstance()); 2759 storage::ExternalMountPoints::GetSystemInstance());
2759 backend->AddSystemMountPoints(); 2760 backend->AddSystemMountPoints();
2760 DCHECK(backend->CanHandleType(storage::kFileSystemTypeExternal)); 2761 DCHECK(backend->CanHandleType(storage::kFileSystemTypeExternal));
2761 additional_backends->push_back(backend); 2762 additional_backends->push_back(backend);
2762 #endif 2763 #endif
2763 2764
2764 for (size_t i = 0; i < extra_parts_.size(); ++i) { 2765 for (size_t i = 0; i < extra_parts_.size(); ++i) {
2765 extra_parts_[i]->GetAdditionalFileSystemBackends( 2766 extra_parts_[i]->GetAdditionalFileSystemBackends(
2766 browser_context, storage_partition_path, additional_backends); 2767 browser_context, storage_partition_path, additional_backends);
2767 } 2768 }
(...skipping 463 matching lines...) Expand 10 before | Expand all | Expand 10 after
3231 kWebRtcDevSwitchNames, 3232 kWebRtcDevSwitchNames,
3232 arraysize(kWebRtcDevSwitchNames)); 3233 arraysize(kWebRtcDevSwitchNames));
3233 } 3234 }
3234 } 3235 }
3235 #endif // defined(ENABLE_WEBRTC) 3236 #endif // defined(ENABLE_WEBRTC)
3236 3237
3237 std::unique_ptr<content::MemoryCoordinatorDelegate> 3238 std::unique_ptr<content::MemoryCoordinatorDelegate>
3238 ChromeContentBrowserClient::GetMemoryCoordinatorDelegate() { 3239 ChromeContentBrowserClient::GetMemoryCoordinatorDelegate() {
3239 return memory::ChromeMemoryCoordinatorDelegate::Create(); 3240 return memory::ChromeMemoryCoordinatorDelegate::Create();
3240 } 3241 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/BUILD.gn » ('j') | chrome/browser/chromeos/fileapi/file_system_backend.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698