| 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/common/chrome_paths_internal.h" | 5 #include "chrome/common/chrome_paths_internal.h" |
| 6 | 6 |
| 7 #include <windows.h> | 7 #include <windows.h> |
| 8 #include <knownfolders.h> | 8 #include <knownfolders.h> |
| 9 #include <shellapi.h> | 9 #include <shellapi.h> |
| 10 #include <shlobj.h> | 10 #include <shlobj.h> |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 | 102 |
| 103 bool GetUserPicturesDirectory(base::FilePath* result) { | 103 bool GetUserPicturesDirectory(base::FilePath* result) { |
| 104 return GetUserDirectory(CSIDL_MYPICTURES, result); | 104 return GetUserDirectory(CSIDL_MYPICTURES, result); |
| 105 } | 105 } |
| 106 | 106 |
| 107 bool GetUserVideosDirectory(base::FilePath* result) { | 107 bool GetUserVideosDirectory(base::FilePath* result) { |
| 108 return GetUserDirectory(CSIDL_MYVIDEO, result); | 108 return GetUserDirectory(CSIDL_MYVIDEO, result); |
| 109 } | 109 } |
| 110 | 110 |
| 111 bool ProcessNeedsProfileDir(const std::string& process_type) { | 111 bool ProcessNeedsProfileDir(const std::string& process_type) { |
| 112 // On windows we don't want subprocesses other than the browser process and | 112 return install_static::ProcessNeedsProfileDir(process_type); |
| 113 // service processes to be able to use the profile directory because if it | |
| 114 // lies on a network share the sandbox will prevent us from accessing it. | |
| 115 | |
| 116 if (process_type.empty() || | |
| 117 process_type == switches::kCloudPrintServiceProcess) | |
| 118 return true; | |
| 119 | |
| 120 #if !defined(DISABLE_NACL) | |
| 121 if (process_type == switches::kNaClBrokerProcess || | |
| 122 process_type == switches::kNaClLoaderProcess) { | |
| 123 return true; | |
| 124 } | |
| 125 #endif | |
| 126 | |
| 127 return false; | |
| 128 } | 113 } |
| 129 | 114 |
| 130 } // namespace chrome | 115 } // namespace chrome |
| OLD | NEW |