OLD | NEW |
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 <set> | 7 #include <set> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 28 matching lines...) Expand all Loading... |
39 #include "chrome/browser/extensions/extension_system.h" | 39 #include "chrome/browser/extensions/extension_system.h" |
40 #include "chrome/browser/extensions/extension_web_ui.h" | 40 #include "chrome/browser/extensions/extension_web_ui.h" |
41 #include "chrome/browser/extensions/extension_webkit_preferences.h" | 41 #include "chrome/browser/extensions/extension_webkit_preferences.h" |
42 #include "chrome/browser/extensions/suggest_permission_util.h" | 42 #include "chrome/browser/extensions/suggest_permission_util.h" |
43 #include "chrome/browser/geolocation/chrome_access_token_store.h" | 43 #include "chrome/browser/geolocation/chrome_access_token_store.h" |
44 #include "chrome/browser/google/google_util.h" | 44 #include "chrome/browser/google/google_util.h" |
45 #include "chrome/browser/guestview/adview/adview_guest.h" | 45 #include "chrome/browser/guestview/adview/adview_guest.h" |
46 #include "chrome/browser/guestview/guestview.h" | 46 #include "chrome/browser/guestview/guestview.h" |
47 #include "chrome/browser/guestview/guestview_constants.h" | 47 #include "chrome/browser/guestview/guestview_constants.h" |
48 #include "chrome/browser/guestview/webview/webview_guest.h" | 48 #include "chrome/browser/guestview/webview/webview_guest.h" |
| 49 #include "chrome/browser/local_discovery/storage/privet_filesystem_backend.h" |
49 #include "chrome/browser/media/media_capture_devices_dispatcher.h" | 50 #include "chrome/browser/media/media_capture_devices_dispatcher.h" |
50 #include "chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.h" | 51 #include "chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.h" |
51 #include "chrome/browser/nacl_host/nacl_browser_delegate_impl.h" | 52 #include "chrome/browser/nacl_host/nacl_browser_delegate_impl.h" |
52 #include "chrome/browser/net/chrome_net_log.h" | 53 #include "chrome/browser/net/chrome_net_log.h" |
53 #include "chrome/browser/notifications/desktop_notification_service.h" | 54 #include "chrome/browser/notifications/desktop_notification_service.h" |
54 #include "chrome/browser/notifications/desktop_notification_service_factory.h" | 55 #include "chrome/browser/notifications/desktop_notification_service_factory.h" |
55 #include "chrome/browser/platform_util.h" | 56 #include "chrome/browser/platform_util.h" |
56 #include "chrome/browser/plugins/plugin_info_message_filter.h" | 57 #include "chrome/browser/plugins/plugin_info_message_filter.h" |
57 #include "chrome/browser/prerender/prerender_final_status.h" | 58 #include "chrome/browser/prerender/prerender_final_status.h" |
58 #include "chrome/browser/prerender/prerender_manager.h" | 59 #include "chrome/browser/prerender/prerender_manager.h" |
(...skipping 2465 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2524 external_mount_points, | 2525 external_mount_points, |
2525 fileapi::ExternalMountPoints::GetSystemInstance()); | 2526 fileapi::ExternalMountPoints::GetSystemInstance()); |
2526 backend->AddSystemMountPoints(); | 2527 backend->AddSystemMountPoints(); |
2527 DCHECK(backend->CanHandleType(fileapi::kFileSystemTypeExternal)); | 2528 DCHECK(backend->CanHandleType(fileapi::kFileSystemTypeExternal)); |
2528 additional_backends->push_back(backend); | 2529 additional_backends->push_back(backend); |
2529 #endif | 2530 #endif |
2530 | 2531 |
2531 additional_backends->push_back( | 2532 additional_backends->push_back( |
2532 new sync_file_system::SyncFileSystemBackend( | 2533 new sync_file_system::SyncFileSystemBackend( |
2533 Profile::FromBrowserContext(browser_context))); | 2534 Profile::FromBrowserContext(browser_context))); |
| 2535 |
| 2536 if (CommandLine::ForCurrentProcess()->HasSwitch( |
| 2537 switches::kEnablePrivetStorage)) { |
| 2538 additional_backends->push_back( |
| 2539 new local_discovery::PrivetFileSystemBackend( |
| 2540 fileapi::ExternalMountPoints::GetSystemInstance())); |
| 2541 } |
2534 } | 2542 } |
2535 | 2543 |
2536 #if defined(OS_POSIX) && !defined(OS_MACOSX) | 2544 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
2537 void ChromeContentBrowserClient::GetAdditionalMappedFilesForChildProcess( | 2545 void ChromeContentBrowserClient::GetAdditionalMappedFilesForChildProcess( |
2538 const CommandLine& command_line, | 2546 const CommandLine& command_line, |
2539 int child_process_id, | 2547 int child_process_id, |
2540 std::vector<FileDescriptorInfo>* mappings) { | 2548 std::vector<FileDescriptorInfo>* mappings) { |
2541 #if defined(OS_ANDROID) | 2549 #if defined(OS_ANDROID) |
2542 base::FilePath data_path; | 2550 base::FilePath data_path; |
2543 PathService::Get(ui::DIR_RESOURCE_PAKS_ANDROID, &data_path); | 2551 PathService::Get(ui::DIR_RESOURCE_PAKS_ANDROID, &data_path); |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2657 // releases of Chrome. Permitting "Unknown" allows these APIs to be used on | 2665 // releases of Chrome. Permitting "Unknown" allows these APIs to be used on |
2658 // Chromium builds as well. | 2666 // Chromium builds as well. |
2659 return channel <= chrome::VersionInfo::CHANNEL_DEV; | 2667 return channel <= chrome::VersionInfo::CHANNEL_DEV; |
2660 #else | 2668 #else |
2661 return false; | 2669 return false; |
2662 #endif | 2670 #endif |
2663 } | 2671 } |
2664 | 2672 |
2665 | 2673 |
2666 } // namespace chrome | 2674 } // namespace chrome |
OLD | NEW |