Fully move PathService into the base namespace.
BUG=838398
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel;master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_compile_x64_dbg;master.tryserver.chromium.android:android_compile_x86_dbg;master.tryserver.chromium.android:android_cronet_tester;master.tryserver.chromium.linux:linux_mojo;master.tryserver.chromium.linux:linux_vr;master.tryserver.chromium.mac:ios-simulator-cronet;master.tryserver.chromium.win:win10_chromium_x64_rel_ng
Change-Id: Ibb79d0d8090cece52d7a20269153718992c8c2d1
Reviewed-on: https://chromium-review.googlesource.com/1036570
Commit-Queue: Avi Drissman <[email protected]>
Reviewed-by: Will Harris <[email protected]>
Reviewed-by: John Abd-El-Malek <[email protected]>
Cr-Commit-Position: refs/heads/master@{#556512}
diff --git a/android_webview/browser/aw_browser_context.cc b/android_webview/browser/aw_browser_context.cc
index fe44b636..6abe2b4 100644
--- a/android_webview/browser/aw_browser_context.cc
+++ b/android_webview/browser/aw_browser_context.cc
@@ -134,7 +134,7 @@
void AwBrowserContext::PreMainMessageLoopRun(net::NetLog* net_log) {
FilePath cache_path;
- PathService::Get(base::DIR_CACHE, &cache_path);
+ base::PathService::Get(base::DIR_CACHE, &cache_path);
cache_path =
cache_path.Append(FILE_PATH_LITERAL("org.chromium.android_webview"));
diff --git a/android_webview/browser/aw_browser_main_parts.cc b/android_webview/browser/aw_browser_main_parts.cc
index 8fe6fc8..bc76207 100644
--- a/android_webview/browser/aw_browser_main_parts.cc
+++ b/android_webview/browser/aw_browser_main_parts.cc
@@ -91,7 +91,7 @@
// Try to directly mmap the resources.pak from the apk. Fall back to load
// from file, using PATH_SERVICE, otherwise.
base::FilePath pak_file_path;
- PathService::Get(ui::DIR_RESOURCE_PAKS_ANDROID, &pak_file_path);
+ base::PathService::Get(ui::DIR_RESOURCE_PAKS_ANDROID, &pak_file_path);
pak_file_path = pak_file_path.AppendASCII("resources.pak");
ui::LoadMainAndroidPackFile("assets/resources.pak", pak_file_path);
@@ -104,15 +104,15 @@
// initially, because safe browsing can be enabled later at runtime
// on a per-webview basis.
base::FilePath safe_browsing_dir;
- if (PathService::Get(android_webview::DIR_SAFE_BROWSING,
- &safe_browsing_dir)) {
+ if (base::PathService::Get(android_webview::DIR_SAFE_BROWSING,
+ &safe_browsing_dir)) {
if (!base::PathExists(safe_browsing_dir))
base::CreateDirectory(safe_browsing_dir);
}
base::FilePath crash_dir;
if (crash_reporter::IsCrashReporterEnabled()) {
- if (PathService::Get(android_webview::DIR_CRASH_DUMPS, &crash_dir)) {
+ if (base::PathService::Get(android_webview::DIR_CRASH_DUMPS, &crash_dir)) {
if (!base::PathExists(crash_dir))
base::CreateDirectory(crash_dir);
}
diff --git a/android_webview/browser/aw_content_browser_client.cc b/android_webview/browser/aw_content_browser_client.cc
index f234314f..0b5fcf28 100644
--- a/android_webview/browser/aw_content_browser_client.cc
+++ b/android_webview/browser/aw_content_browser_client.cc
@@ -216,7 +216,7 @@
AwBrowserContext* AwContentBrowserClient::InitBrowserContext() {
base::FilePath user_data_dir;
- if (!PathService::Get(base::DIR_ANDROID_APP_DATA, &user_data_dir)) {
+ if (!base::PathService::Get(base::DIR_ANDROID_APP_DATA, &user_data_dir)) {
NOTREACHED() << "Failed to get app data directory for Android WebView";
}
browser_context_.reset(new AwBrowserContext(user_data_dir));
diff --git a/android_webview/browser/aw_metrics_service_client.cc b/android_webview/browser/aw_metrics_service_client.cc
index 3afecd0..ea6ccb9 100644
--- a/android_webview/browser/aw_metrics_service_client.cc
+++ b/android_webview/browser/aw_metrics_service_client.cc
@@ -87,7 +87,7 @@
// anonymously identify logs. Every WebView-using app on every device
// is given a GUID, stored in this file in the app's data directory.
base::FilePath user_data_dir;
- if (!PathService::Get(base::DIR_ANDROID_APP_DATA, &user_data_dir)) {
+ if (!base::PathService::Get(base::DIR_ANDROID_APP_DATA, &user_data_dir)) {
LOG(ERROR) << "Failed to get app data directory for Android WebView";
// Generate a 1-time GUID so metrics can still be collected
diff --git a/android_webview/browser/aw_safe_browsing_ui_manager.cc b/android_webview/browser/aw_safe_browsing_ui_manager.cc
index ee072f7..35a2e9c5 100644
--- a/android_webview/browser/aw_safe_browsing_ui_manager.cc
+++ b/android_webview/browser/aw_safe_browsing_ui_manager.cc
@@ -45,8 +45,8 @@
// TODO(timvolodine): verify this is what we want regarding the directory.
base::FilePath user_data_dir;
- bool result =
- PathService::Get(android_webview::DIR_SAFE_BROWSING, &user_data_dir);
+ bool result = base::PathService::Get(android_webview::DIR_SAFE_BROWSING,
+ &user_data_dir);
DCHECK(result);
url_request_context_getter_ =
diff --git a/android_webview/browser/cookie_manager.cc b/android_webview/browser/cookie_manager.cc
index f92fbad3..0b33a050 100644
--- a/android_webview/browser/cookie_manager.cc
+++ b/android_webview/browser/cookie_manager.cc
@@ -120,7 +120,7 @@
const bool kDefaultFileSchemeAllowed = false;
void GetUserDataDir(FilePath* user_data_dir) {
- if (!PathService::Get(base::DIR_ANDROID_APP_DATA, user_data_dir)) {
+ if (!base::PathService::Get(base::DIR_ANDROID_APP_DATA, user_data_dir)) {
NOTREACHED() << "Failed to get app data directory for Android WebView";
}
}
diff --git a/android_webview/browser/net/aw_url_request_context_getter.cc b/android_webview/browser/net/aw_url_request_context_getter.cc
index 600c364..c3e26c2 100644
--- a/android_webview/browser/net/aw_url_request_context_getter.cc
+++ b/android_webview/browser/net/aw_url_request_context_getter.cc
@@ -241,7 +241,7 @@
*base::CommandLine::ForCurrentProcess();
if (command_line.HasSwitch(network::switches::kLogNetLog)) {
FilePath net_log_path;
- PathService::Get(base::DIR_ANDROID_APP_DATA, &net_log_path);
+ base::PathService::Get(base::DIR_ANDROID_APP_DATA, &net_log_path);
FilePath log_name =
command_line.GetSwitchValuePath(network::switches::kLogNetLog);
net_log_path = net_log_path.Append(log_name);
diff --git a/android_webview/common/aw_paths.cc b/android_webview/common/aw_paths.cc
index 390a7be..99887b2 100644
--- a/android_webview/common/aw_paths.cc
+++ b/android_webview/common/aw_paths.cc
@@ -36,7 +36,7 @@
}
void RegisterPathProvider() {
- PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
+ base::PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
}
} // namespace android_webview
diff --git a/android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc b/android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc
index 6e0ccba8..d87aa2d 100644
--- a/android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc
+++ b/android_webview/common/crash_reporter/aw_microdump_crash_reporter.cc
@@ -82,7 +82,7 @@
}
bool GetCrashDumpLocation(base::FilePath* crash_dir) override {
- return PathService::Get(android_webview::DIR_CRASH_DUMPS, crash_dir);
+ return base::PathService::Get(android_webview::DIR_CRASH_DUMPS, crash_dir);
}
private:
diff --git a/ash/app_list/presenter/test/run_all_unittests.cc b/ash/app_list/presenter/test/run_all_unittests.cc
index 1a3bae5..57609924 100644
--- a/ash/app_list/presenter/test/run_all_unittests.cc
+++ b/ash/app_list/presenter/test/run_all_unittests.cc
@@ -27,7 +27,7 @@
ui::RegisterPathProvider();
base::FilePath ui_test_pak_path;
- ASSERT_TRUE(PathService::Get(ui::UI_TEST_PAK, &ui_test_pak_path));
+ ASSERT_TRUE(base::PathService::Get(ui::UI_TEST_PAK, &ui_test_pak_path));
ui::ResourceBundle::InitSharedInstanceWithPakPath(ui_test_pak_path);
}
diff --git a/ash/display/display_color_manager_unittest.cc b/ash/display/display_color_manager_unittest.cc
index 2f2ce3f..3ddd13a6 100644
--- a/ash/display/display_color_manager_unittest.cc
+++ b/ash/display/display_color_manager_unittest.cc
@@ -115,7 +115,7 @@
color_manager_ =
std::make_unique<DisplayColorManagerForTest>(&configurator_);
- EXPECT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &color_path_));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &color_path_));
color_path_ = color_path_.Append(FILE_PATH_LITERAL("ash"))
.Append(FILE_PATH_LITERAL("display"))
diff --git a/ash/shell/content/client/shell_main_delegate.cc b/ash/shell/content/client/shell_main_delegate.cc
index 6fece30..8c56e98 100644
--- a/ash/shell/content/client/shell_main_delegate.cc
+++ b/ash/shell/content/client/shell_main_delegate.cc
@@ -83,7 +83,7 @@
void ShellMainDelegate::InitializeResourceBundle() {
// Load ash resources and strings; not 'common' (Chrome) resources.
base::FilePath path;
- PathService::Get(base::DIR_MODULE, &path);
+ base::PathService::Get(base::DIR_MODULE, &path);
base::FilePath ash_test_strings =
path.Append(FILE_PATH_LITERAL("ash_test_strings.pak"));
diff --git a/ash/shell/content/shell_with_content_main.cc b/ash/shell/content/shell_with_content_main.cc
index 55e159b..c30d500e 100644
--- a/ash/shell/content/shell_with_content_main.cc
+++ b/ash/shell/content/shell_with_content_main.cc
@@ -14,7 +14,7 @@
base::AtExitManager exit_manager;
base::FilePath log_filename;
- PathService::Get(base::DIR_EXE, &log_filename);
+ base::PathService::Get(base::DIR_EXE, &log_filename);
log_filename = log_filename.AppendASCII("ash_shell.log");
logging::LoggingSettings settings;
settings.logging_dest = logging::LOG_TO_ALL;
diff --git a/ash/test/ash_interactive_ui_test_base.cc b/ash/test/ash_interactive_ui_test_base.cc
index b0616ce..3fb9e511 100644
--- a/ash/test/ash_interactive_ui_test_base.cc
+++ b/ash/test/ash_interactive_ui_test_base.cc
@@ -43,7 +43,7 @@
ui::ResourceBundle::InitSharedInstanceWithLocale(
"en-US", NULL, ui::ResourceBundle::LOAD_COMMON_RESOURCES);
base::FilePath resources_pack_path;
- PathService::Get(base::DIR_MODULE, &resources_pack_path);
+ base::PathService::Get(base::DIR_MODULE, &resources_pack_path);
resources_pack_path =
resources_pack_path.Append(FILE_PATH_LITERAL("resources.pak"));
ui::ResourceBundle::GetSharedInstance().AddDataPackFromPath(
diff --git a/ash/test/ash_test_suite.cc b/ash/test/ash_test_suite.cc
index ee7b43d..4c17af8 100644
--- a/ash/test/ash_test_suite.cc
+++ b/ash/test/ash_test_suite.cc
@@ -42,7 +42,7 @@
// Load ash test resources and en-US strings; not 'common' (Chrome) resources.
base::FilePath path;
- PathService::Get(base::DIR_MODULE, &path);
+ base::PathService::Get(base::DIR_MODULE, &path);
base::FilePath ash_test_strings =
path.Append(FILE_PATH_LITERAL("ash_test_strings.pak"));
ui::ResourceBundle::InitSharedInstanceWithPakPath(ash_test_strings);
diff --git a/base/file_version_info_win_unittest.cc b/base/file_version_info_win_unittest.cc
index b5788fe..a4acc4ca3 100644
--- a/base/file_version_info_win_unittest.cc
+++ b/base/file_version_info_win_unittest.cc
@@ -24,7 +24,7 @@
FilePath GetTestDataPath() {
FilePath path;
- PathService::Get(base::DIR_SOURCE_ROOT, &path);
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &path);
path = path.AppendASCII("base");
path = path.AppendASCII("test");
path = path.AppendASCII("data");
diff --git a/base/path_service.h b/base/path_service.h
index c7f1abe71..9b4715f 100644
--- a/base/path_service.h
+++ b/base/path_service.h
@@ -91,7 +91,4 @@
} // namespace base
-// TODO(brettw) Convert all callers to using the base namespace and remove this.
-using base::PathService;
-
#endif // BASE_PATH_SERVICE_H_
diff --git a/base/test/generate_fontconfig_caches.cc b/base/test/generate_fontconfig_caches.cc
index 681ed24..f12eb481 100644
--- a/base/test/generate_fontconfig_caches.cc
+++ b/base/test/generate_fontconfig_caches.cc
@@ -14,7 +14,7 @@
base::TearDownFontconfig();
base::FilePath dir_module;
- CHECK(PathService::Get(base::DIR_MODULE, &dir_module));
+ CHECK(base::PathService::Get(base::DIR_MODULE, &dir_module));
base::FilePath fontconfig_caches = dir_module.Append("fontconfig_caches");
CHECK(base::DirectoryExists(fontconfig_caches));
base::FilePath stamp = fontconfig_caches.Append("STAMP");
diff --git a/base/test/test_support_android.cc b/base/test/test_support_android.cc
index 86a734a..33a6628 100644
--- a/base/test/test_support_android.cc
+++ b/base/test/test_support_android.cc
@@ -154,8 +154,10 @@
void InitPathProvider(int key) {
base::FilePath path;
// If failed to override the key, that means the way has not been registered.
- if (GetTestProviderPath(key, &path) && !PathService::Override(key, path))
- PathService::RegisterProvider(&GetTestProviderPath, key, key + 1);
+ if (GetTestProviderPath(key, &path) &&
+ !base::PathService::Override(key, path)) {
+ base::PathService::RegisterProvider(&GetTestProviderPath, key, key + 1);
+ }
}
} // namespace
diff --git a/cc/test/layer_tree_pixel_test.cc b/cc/test/layer_tree_pixel_test.cc
index b0dd897..5f94532 100644
--- a/cc/test/layer_tree_pixel_test.cc
+++ b/cc/test/layer_tree_pixel_test.cc
@@ -120,7 +120,8 @@
void LayerTreePixelTest::AfterTest() {
base::FilePath test_data_dir;
- EXPECT_TRUE(PathService::Get(viz::Paths::DIR_TEST_DATA, &test_data_dir));
+ EXPECT_TRUE(
+ base::PathService::Get(viz::Paths::DIR_TEST_DATA, &test_data_dir));
base::FilePath ref_file_path = test_data_dir.Append(ref_file_);
base::CommandLine* cmd = base::CommandLine::ForCurrentProcess();
diff --git a/cc/test/pixel_test.cc b/cc/test/pixel_test.cc
index 2d86b840..6dd3be2 100644
--- a/cc/test/pixel_test.cc
+++ b/cc/test/pixel_test.cc
@@ -147,7 +147,7 @@
bool PixelTest::PixelsMatchReference(const base::FilePath& ref_file,
const PixelComparator& comparator) {
base::FilePath test_data_dir;
- if (!PathService::Get(viz::Paths::DIR_TEST_DATA, &test_data_dir))
+ if (!base::PathService::Get(viz::Paths::DIR_TEST_DATA, &test_data_dir))
return false;
// If this is false, we didn't set up a readback on a render pass.
diff --git a/cc/trees/layer_tree_host_common_perftest.cc b/cc/trees/layer_tree_host_common_perftest.cc
index f411b4e..e599a6b4 100644
--- a/cc/trees/layer_tree_host_common_perftest.cc
+++ b/cc/trees/layer_tree_host_common_perftest.cc
@@ -40,7 +40,8 @@
void ReadTestFile(const std::string& name) {
base::FilePath test_data_dir;
- ASSERT_TRUE(PathService::Get(viz::Paths::DIR_TEST_DATA, &test_data_dir));
+ ASSERT_TRUE(
+ base::PathService::Get(viz::Paths::DIR_TEST_DATA, &test_data_dir));
base::FilePath json_file = test_data_dir.AppendASCII(name + ".json");
ASSERT_TRUE(base::ReadFileToString(json_file, &json_));
}
diff --git a/cc/trees/layer_tree_host_perftest.cc b/cc/trees/layer_tree_host_perftest.cc
index 2cd64729..871e1a1 100644
--- a/cc/trees/layer_tree_host_perftest.cc
+++ b/cc/trees/layer_tree_host_perftest.cc
@@ -139,7 +139,8 @@
void ReadTestFile(const std::string& name) {
base::FilePath test_data_dir;
- ASSERT_TRUE(PathService::Get(viz::Paths::DIR_TEST_DATA, &test_data_dir));
+ ASSERT_TRUE(
+ base::PathService::Get(viz::Paths::DIR_TEST_DATA, &test_data_dir));
base::FilePath json_file = test_data_dir.AppendASCII(name + ".json");
ASSERT_TRUE(base::ReadFileToString(json_file, &json_));
}
diff --git a/chrome/app/chrome_main_delegate.cc b/chrome/app/chrome_main_delegate.cc
index 8f08d3ff..08ace06 100644
--- a/chrome/app/chrome_main_delegate.cc
+++ b/chrome/app/chrome_main_delegate.cc
@@ -1100,7 +1100,7 @@
#endif
base::FilePath resources_pack_path;
- PathService::Get(chrome::FILE_RESOURCES_PACK, &resources_pack_path);
+ base::PathService::Get(chrome::FILE_RESOURCES_PACK, &resources_pack_path);
#if defined(OS_ANDROID)
service_manifest_data_pack_ =
diff --git a/chrome/app/main_dll_loader_win.cc b/chrome/app/main_dll_loader_win.cc
index d286a71..003a3e52 100644
--- a/chrome/app/main_dll_loader_win.cc
+++ b/chrome/app/main_dll_loader_win.cc
@@ -244,7 +244,7 @@
// Launch the watcher process.
base::FilePath exe_path;
- if (PathService::Get(base::FILE_EXE, &exe_path)) {
+ if (base::PathService::Get(base::FILE_EXE, &exe_path)) {
chrome_watcher_client_.reset(new ChromeWatcherClient(
base::Bind(&GenerateChromeWatcherCommandLine, exe_path)));
chrome_watcher_client_->LaunchWatcher();
diff --git a/chrome/browser/android/webapk/webapk_icon_hasher_unittest.cc b/chrome/browser/android/webapk/webapk_icon_hasher_unittest.cc
index f9465ca..08d42ba2 100644
--- a/chrome/browser/android/webapk/webapk_icon_hasher_unittest.cc
+++ b/chrome/browser/android/webapk/webapk_icon_hasher_unittest.cc
@@ -92,7 +92,7 @@
"http://www.google.com/chrome/test/data/android/google.png";
base::FilePath source_path;
base::FilePath icon_path;
- ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &source_path));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &source_path));
icon_path = source_path.AppendASCII("chrome")
.AppendASCII("test")
.AppendASCII("data")
diff --git a/chrome/browser/chrome_browser_main_win.cc b/chrome/browser/chrome_browser_main_win.cc
index bcb1a7a590..30ebf242 100644
--- a/chrome/browser/chrome_browser_main_win.cc
+++ b/chrome/browser/chrome_browser_main_win.cc
@@ -426,7 +426,7 @@
// work done by setup.exe on uninstall.
VLOG(1) << "Executing uninstall actions";
base::FilePath chrome_exe;
- if (PathService::Get(base::FILE_EXE, &chrome_exe)) {
+ if (base::PathService::Get(base::FILE_EXE, &chrome_exe)) {
ShellUtil::ShortcutLocation user_shortcut_locations[] = {
ShellUtil::SHORTCUT_LOCATION_DESKTOP,
ShellUtil::SHORTCUT_LOCATION_QUICK_LAUNCH,
diff --git a/chrome/browser/chromeos/chrome_browser_main_chromeos.cc b/chrome/browser/chromeos/chrome_browser_main_chromeos.cc
index 3bacb389..bd8ee0d2 100644
--- a/chrome/browser/chromeos/chrome_browser_main_chromeos.cc
+++ b/chrome/browser/chromeos/chrome_browser_main_chromeos.cc
@@ -272,7 +272,7 @@
base::FilePath user_data_dir;
if (base::SysInfo::IsRunningOnChromeOS() ||
- !PathService::Get(chrome::DIR_USER_DATA, &user_data_dir)) {
+ !base::PathService::Get(chrome::DIR_USER_DATA, &user_data_dir)) {
return;
}
diff --git a/chrome/browser/chromeos/login/test/https_forwarder.cc b/chrome/browser/chromeos/login/test/https_forwarder.cc
index be3d5d0..67c285f 100644
--- a/chrome/browser/chromeos/login/test/https_forwarder.cc
+++ b/chrome/browser/chromeos/login/test/https_forwarder.cc
@@ -83,7 +83,7 @@
base::DictionaryValue* arguments) const {
base::FilePath source_root_dir;
if (!net::LocalTestServer::GenerateAdditionalArguments(arguments) ||
- !PathService::Get(base::DIR_SOURCE_ROOT, &source_root_dir))
+ !base::PathService::Get(base::DIR_SOURCE_ROOT, &source_root_dir))
return false;
arguments->SetString("ssl-host", ssl_host_);
diff --git a/chrome/browser/extensions/extension_nacl_browsertest.cc b/chrome/browser/extensions/extension_nacl_browsertest.cc
index 05af192..37d66d1e 100644
--- a/chrome/browser/extensions/extension_nacl_browsertest.cc
+++ b/chrome/browser/extensions/extension_nacl_browsertest.cc
@@ -115,7 +115,7 @@
bool IsNaClPluginLoaded() {
base::FilePath path;
- if (PathService::Get(chrome::FILE_NACL_PLUGIN, &path)) {
+ if (base::PathService::Get(chrome::FILE_NACL_PLUGIN, &path)) {
// Make sure plugins are loaded off disk first.
{
base::RunLoop run_loop;
diff --git a/chrome/browser/net/chrome_network_delegate.cc b/chrome/browser/net/chrome_network_delegate.cc
index 68b06dd..3ca513a 100644
--- a/chrome/browser/net/chrome_network_delegate.cc
+++ b/chrome/browser/net/chrome_network_delegate.cc
@@ -148,7 +148,7 @@
};
base::FilePath temp_dir;
- if (PathService::Get(base::DIR_TEMP, &temp_dir))
+ if (base::PathService::Get(base::DIR_TEMP, &temp_dir))
whitelist.push_back(temp_dir);
// The actual location of "/home/chronos/user/Xyz" is the Xyz directory under
diff --git a/chrome/browser/offline_pages/android/offline_page_model_factory.cc b/chrome/browser/offline_pages/android/offline_page_model_factory.cc
index 791f0c6..350dc4f3 100644
--- a/chrome/browser/offline_pages/android/offline_page_model_factory.cc
+++ b/chrome/browser/offline_pages/android/offline_page_model_factory.cc
@@ -58,7 +58,7 @@
// If base::PathService::Get returns false, the temporary_archives_dir will be
// empty, and no temporary pages will be saved during this chrome lifecycle.
base::FilePath temporary_archives_dir;
- if (PathService::Get(base::DIR_CACHE, &temporary_archives_dir)) {
+ if (base::PathService::Get(base::DIR_CACHE, &temporary_archives_dir)) {
temporary_archives_dir =
temporary_archives_dir.Append(chrome::kOfflinePageArchivesDirname);
}
diff --git a/chrome/browser/offline_pages/test_offline_page_model_builder.cc b/chrome/browser/offline_pages/test_offline_page_model_builder.cc
index 8644bb07..8adc31e 100644
--- a/chrome/browser/offline_pages/test_offline_page_model_builder.cc
+++ b/chrome/browser/offline_pages/test_offline_page_model_builder.cc
@@ -40,7 +40,7 @@
// If base::PathService::Get returns false, the temporary_archives_dir will be
// empty, and no temporary pages will be saved during this chrome lifecycle.
base::FilePath temporary_archives_dir;
- if (PathService::Get(base::DIR_CACHE, &temporary_archives_dir)) {
+ if (base::PathService::Get(base::DIR_CACHE, &temporary_archives_dir)) {
temporary_archives_dir =
temporary_archives_dir.Append(chrome::kOfflinePageArchivesDirname);
}
diff --git a/chrome/browser/printing/pdf_to_emf_converter_browsertest.cc b/chrome/browser/printing/pdf_to_emf_converter_browsertest.cc
index f6b67d8..3d7274a 100644
--- a/chrome/browser/printing/pdf_to_emf_converter_browsertest.cc
+++ b/chrome/browser/printing/pdf_to_emf_converter_browsertest.cc
@@ -192,7 +192,7 @@
private:
base::FilePath GetTestDataDir() const {
base::FilePath test_data_dir;
- if (PathService::Get(chrome::DIR_TEST_DATA, &test_data_dir))
+ if (base::PathService::Get(chrome::DIR_TEST_DATA, &test_data_dir))
test_data_dir = test_data_dir.AppendASCII("printing");
else
test_data_dir.clear();
diff --git a/chrome/browser/shell_integration_linux.cc b/chrome/browser/shell_integration_linux.cc
index 8a3a1056..169c990 100644
--- a/chrome/browser/shell_integration_linux.cc
+++ b/chrome/browser/shell_integration_linux.cc
@@ -368,7 +368,7 @@
void DeleteShortcutOnDesktop(const base::FilePath& shortcut_filename) {
base::FilePath desktop_path;
- if (PathService::Get(base::DIR_USER_DESKTOP, &desktop_path))
+ if (base::PathService::Get(base::DIR_USER_DESKTOP, &desktop_path))
base::DeleteFile(desktop_path.Append(shortcut_filename), false);
}
@@ -1091,7 +1091,7 @@
// Delete shortcuts from Desktop.
base::FilePath desktop_path;
- if (PathService::Get(base::DIR_USER_DESKTOP, &desktop_path)) {
+ if (base::PathService::Get(base::DIR_USER_DESKTOP, &desktop_path)) {
std::vector<base::FilePath> shortcut_filenames_desktop =
GetExistingProfileShortcutFilenames(profile_path, desktop_path);
for (const auto& shortcut : shortcut_filenames_desktop) {
diff --git a/chrome/browser/task_manager/sampling/shared_sampler_win.cc b/chrome/browser/task_manager/sampling/shared_sampler_win.cc
index e57d4a31..9fec432 100644
--- a/chrome/browser/task_manager/sampling/shared_sampler_win.cc
+++ b/chrome/browser/task_manager/sampling/shared_sampler_win.cc
@@ -340,7 +340,7 @@
std::vector<base::FilePath> supported_names;
base::FilePath current_exe;
- if (PathService::Get(base::FILE_EXE, ¤t_exe))
+ if (base::PathService::Get(base::FILE_EXE, ¤t_exe))
supported_names.push_back(current_exe.BaseName());
supported_names.push_back(
diff --git a/chrome/browser/ui/webui/chromeos/drive_internals_ui.cc b/chrome/browser/ui/webui/chromeos/drive_internals_ui.cc
index 2000125..2e2222c 100644
--- a/chrome/browser/ui/webui/chromeos/drive_internals_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/drive_internals_ui.cc
@@ -712,7 +712,7 @@
// Propagate the amount of local free space in bytes.
base::FilePath home_path;
- if (PathService::Get(base::DIR_HOME, &home_path)) {
+ if (base::PathService::Get(base::DIR_HOME, &home_path)) {
base::DictionaryValue* local_storage_summary = new base::DictionaryValue;
base::PostTaskWithTraitsAndReply(
FROM_HERE, {base::MayBlock(), base::TaskPriority::USER_VISIBLE},
diff --git a/chrome/browser/web_applications/web_app_win.cc b/chrome/browser/web_applications/web_app_win.cc
index 218f41d..2b245b28 100644
--- a/chrome/browser/web_applications/web_app_win.cc
+++ b/chrome/browser/web_applications/web_app_win.cc
@@ -305,7 +305,7 @@
if (was_pinned_to_taskbar) {
// Determine if there is a link to this app in the TaskBar pin directory.
base::FilePath taskbar_pin_path;
- if (PathService::Get(base::DIR_TASKBAR_PINS, &taskbar_pin_path)) {
+ if (base::PathService::Get(base::DIR_TASKBAR_PINS, &taskbar_pin_path)) {
std::vector<base::FilePath> taskbar_pin_files =
FindAppShortcutsByProfileAndTitle(taskbar_pin_path, profile_path,
title);
diff --git a/chrome/installer/util/helper.cc b/chrome/installer/util/helper.cc
index 1b5b94e..9019ba9 100644
--- a/chrome/installer/util/helper.cc
+++ b/chrome/installer/util/helper.cc
@@ -20,7 +20,7 @@
#else
int key = system_install ? base::DIR_PROGRAM_FILES : base::DIR_LOCAL_APP_DATA;
#endif
- if (PathService::Get(key, &install_path)) {
+ if (base::PathService::Get(key, &install_path)) {
install_path =
install_path.Append(install_static::GetChromeInstallSubDirectory());
install_path = install_path.Append(kInstallBinaryDir);
diff --git a/chrome/installer/util/install_util.cc b/chrome/installer/util/install_util.cc
index 4afc7e0c..7eeff9d 100644
--- a/chrome/installer/util/install_util.cc
+++ b/chrome/installer/util/install_util.cc
@@ -275,7 +275,7 @@
bool InstallUtil::IsFirstRunSentinelPresent() {
// TODO(msw): Consolidate with first_run::internal::IsFirstRunSentinelPresent.
base::FilePath user_data_dir;
- return !PathService::Get(chrome::DIR_USER_DATA, &user_data_dir) ||
+ return !base::PathService::Get(chrome::DIR_USER_DATA, &user_data_dir) ||
base::PathExists(user_data_dir.Append(chrome::kFirstRunSentinel));
}
diff --git a/chrome/installer/util/logging_installer.cc b/chrome/installer/util/logging_installer.cc
index 7e184ee..78dfa44c 100644
--- a/chrome/installer/util/logging_installer.cc
+++ b/chrome/installer/util/logging_installer.cc
@@ -123,7 +123,7 @@
// Fallback to current directory if getting the temp directory fails.
base::FilePath tmp_path;
- ignore_result(PathService::Get(base::DIR_TEMP, &tmp_path));
+ ignore_result(base::PathService::Get(base::DIR_TEMP, &tmp_path));
return tmp_path.Append(kLogFilename);
}
diff --git a/chrome/test/chromedriver/chrome/chrome_finder.cc b/chrome/test/chromedriver/chrome/chrome_finder.cc
index 2554ed60..9115579 100644
--- a/chrome/test/chromedriver/chrome/chrome_finder.cc
+++ b/chrome/test/chromedriver/chrome/chrome_finder.cc
@@ -29,11 +29,11 @@
void GetApplicationDirs(std::vector<base::FilePath>* locations) {
std::vector<base::FilePath> installation_locations;
base::FilePath local_app_data, program_files, program_files_x86;
- if (PathService::Get(base::DIR_LOCAL_APP_DATA, &local_app_data))
+ if (base::PathService::Get(base::DIR_LOCAL_APP_DATA, &local_app_data))
installation_locations.push_back(local_app_data);
- if (PathService::Get(base::DIR_PROGRAM_FILES, &program_files))
+ if (base::PathService::Get(base::DIR_PROGRAM_FILES, &program_files))
installation_locations.push_back(program_files);
- if (PathService::Get(base::DIR_PROGRAM_FILESX86, &program_files_x86))
+ if (base::PathService::Get(base::DIR_PROGRAM_FILESX86, &program_files_x86))
installation_locations.push_back(program_files_x86);
for (size_t i = 0; i < installation_locations.size(); ++i) {
@@ -112,7 +112,7 @@
std::vector<base::FilePath> browser_exes(
browser_exes_array, browser_exes_array + arraysize(browser_exes_array));
base::FilePath module_dir;
- if (PathService::Get(base::DIR_MODULE, &module_dir)) {
+ if (base::PathService::Get(base::DIR_MODULE, &module_dir)) {
for (size_t i = 0; i < browser_exes.size(); ++i) {
base::FilePath path = module_dir.Append(browser_exes[i]);
if (base::PathExists(path)) {
diff --git a/chrome_elf/blacklist/test/blacklist_test.cc b/chrome_elf/blacklist/test/blacklist_test.cc
index 4a61f0c..4008da5 100644
--- a/chrome_elf/blacklist/test/blacklist_test.cc
+++ b/chrome_elf/blacklist/test/blacklist_test.cc
@@ -71,7 +71,7 @@
void CheckBlacklistedDllsNotLoaded() {
base::FilePath current_dir;
- ASSERT_TRUE(PathService::Get(base::DIR_EXE, ¤t_dir));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_EXE, ¤t_dir));
for (size_t i = 0; i < arraysize(test_data); ++i) {
// Ensure that the dll has not been loaded both by inspecting the handle
@@ -287,7 +287,7 @@
// Disabled due to flakiness. https://crbug.com/711651.
TEST_F(BlacklistTest, DISABLED_LoadBlacklistedLibrary) {
base::FilePath current_dir;
- ASSERT_TRUE(PathService::Get(base::DIR_EXE, ¤t_dir));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_EXE, ¤t_dir));
// Ensure that the blacklist is loaded.
ASSERT_TRUE(TestDll_IsBlacklistInitialized());
diff --git a/chrome_elf/elf_imports_unittest.cc b/chrome_elf/elf_imports_unittest.cc
index cd2b4772..6c7e29f 100644
--- a/chrome_elf/elf_imports_unittest.cc
+++ b/chrome_elf/elf_imports_unittest.cc
@@ -73,7 +73,7 @@
TEST_F(ELFImportsTest, ChromeElfSanityCheck) {
base::FilePath dll;
- ASSERT_TRUE(PathService::Get(base::DIR_EXE, &dll));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_EXE, &dll));
dll = dll.Append(L"chrome_elf.dll");
std::vector<std::string> elf_imports;
@@ -141,7 +141,7 @@
// added to the command line.
TEST_F(ELFImportsTest, DISABLED_ChromeElfLoadSanityTestImpl) {
base::FilePath dll;
- ASSERT_TRUE(PathService::Get(base::DIR_EXE, &dll));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_EXE, &dll));
dll = dll.Append(L"chrome_elf.dll");
// We don't expect user32 to be loaded in chrome_elf_import_unittests. If this
@@ -164,7 +164,7 @@
std::vector<std::string> exe_imports;
base::FilePath exe;
- ASSERT_TRUE(PathService::Get(base::DIR_EXE, &exe));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_EXE, &exe));
exe = exe.Append(L"chrome.exe");
GetImports(exe, &exe_imports);
diff --git a/chromecast/app/android/cast_crash_reporter_client_android.cc b/chromecast/app/android/cast_crash_reporter_client_android.cc
index d17fa21..52659e5 100644
--- a/chromecast/app/android/cast_crash_reporter_client_android.cc
+++ b/chromecast/app/android/cast_crash_reporter_client_android.cc
@@ -43,7 +43,7 @@
const std::string& process_type,
base::FilePath* crash_dir) {
base::FilePath crash_dir_local;
- if (!PathService::Get(base::DIR_ANDROID_APP_DATA, &crash_dir_local)) {
+ if (!base::PathService::Get(base::DIR_ANDROID_APP_DATA, &crash_dir_local)) {
return false;
}
crash_dir_local = crash_dir_local.Append("crashes");
diff --git a/chromecast/app/cast_main_delegate.cc b/chromecast/app/cast_main_delegate.cc
index c77fc82..991d46d 100644
--- a/chromecast/app/cast_main_delegate.cc
+++ b/chromecast/app/cast_main_delegate.cc
@@ -72,7 +72,7 @@
// Browser process logs are recorded for attaching with crash dumps.
if (process_type.empty()) {
base::FilePath log_file;
- PathService::Get(FILE_CAST_ANDROID_LOG, &log_file);
+ base::PathService::Get(FILE_CAST_ANDROID_LOG, &log_file);
settings.logging_dest = logging::LOG_TO_ALL;
settings.log_file = log_file.value().c_str();
settings.delete_old = logging::DELETE_OLD_LOG_FILE;
@@ -142,7 +142,7 @@
// TODO(crbug.com/753619): Enable crash reporting on Fuchsia.
#if defined(OS_ANDROID)
base::FilePath log_file;
- PathService::Get(FILE_CAST_ANDROID_LOG, &log_file);
+ base::PathService::Get(FILE_CAST_ANDROID_LOG, &log_file);
chromecast::CrashHandler::Initialize(process_type, log_file);
#elif defined(OS_LINUX)
crash_reporter::SetCrashReporterClient(g_crash_reporter_client.Pointer());
@@ -184,7 +184,7 @@
void CastMainDelegate::InitializeResourceBundle() {
base::FilePath pak_file;
- CHECK(PathService::Get(FILE_CAST_PAK, &pak_file));
+ CHECK(base::PathService::Get(FILE_CAST_PAK, &pak_file));
#if defined(OS_ANDROID)
// On Android, the renderer runs with a different UID and can never access
// the file system. Use the file descriptor passed in at launch time.
diff --git a/chromecast/base/cast_paths.cc b/chromecast/base/cast_paths.cc
index 595621b..3c246c9f 100644
--- a/chromecast/base/cast_paths.cc
+++ b/chromecast/base/cast_paths.cc
@@ -32,7 +32,7 @@
#if defined(OS_ANDROID)
case FILE_CAST_ANDROID_LOG: {
base::FilePath base_dir;
- CHECK(PathService::Get(base::DIR_ANDROID_APP_DATA, &base_dir));
+ CHECK(base::PathService::Get(base::DIR_ANDROID_APP_DATA, &base_dir));
*result = base_dir.AppendASCII("cast_shell.log");
return true;
}
@@ -40,10 +40,10 @@
case FILE_CAST_CONFIG: {
base::FilePath data_dir;
#if defined(OS_ANDROID)
- CHECK(PathService::Get(base::DIR_ANDROID_APP_DATA, &data_dir));
+ CHECK(base::PathService::Get(base::DIR_ANDROID_APP_DATA, &data_dir));
*result = data_dir.Append("cast_shell.conf");
#else
- CHECK(PathService::Get(DIR_CAST_HOME, &data_dir));
+ CHECK(base::PathService::Get(DIR_CAST_HOME, &data_dir));
*result = data_dir.Append(".eureka.conf");
#endif // defined(OS_ANDROID)
return true;
@@ -51,10 +51,10 @@
case FILE_CAST_CRL: {
base::FilePath data_dir;
#if defined(OS_ANDROID)
- CHECK(PathService::Get(base::DIR_ANDROID_APP_DATA, &data_dir));
+ CHECK(base::PathService::Get(base::DIR_ANDROID_APP_DATA, &data_dir));
*result = data_dir.Append("cast_shell.crl");
#else
- CHECK(PathService::Get(DIR_CAST_HOME, &data_dir));
+ CHECK(base::PathService::Get(DIR_CAST_HOME, &data_dir));
*result = data_dir.Append(".eureka.crl");
#endif // defined(OS_ANDROID)
return true;
@@ -62,10 +62,10 @@
case FILE_CAST_PAK: {
base::FilePath base_dir;
#if defined(OS_ANDROID)
- CHECK(PathService::Get(base::DIR_ANDROID_APP_DATA, &base_dir));
+ CHECK(base::PathService::Get(base::DIR_ANDROID_APP_DATA, &base_dir));
*result = base_dir.Append("paks/cast_shell.pak");
#else
- CHECK(PathService::Get(base::DIR_MODULE, &base_dir));
+ CHECK(base::PathService::Get(base::DIR_MODULE, &base_dir));
*result = base_dir.Append("assets/cast_shell.pak");
#endif // defined(OS_ANDROID)
return true;
@@ -75,7 +75,7 @@
}
void RegisterPathProvider() {
- PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
+ base::PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
}
} // namespace chromecast
diff --git a/chromecast/base/path_utils.cc b/chromecast/base/path_utils.cc
index 4f5b27b7..3becd03c 100644
--- a/chromecast/base/path_utils.cc
+++ b/chromecast/base/path_utils.cc
@@ -17,7 +17,7 @@
return path;
base::FilePath default_dir;
- if (!PathService::Get(default_dir_key, &default_dir))
+ if (!base::PathService::Get(default_dir_key, &default_dir))
LOG(DFATAL) << "Cannot get default dir: " << default_dir_key;
base::FilePath adjusted_path(default_dir.Append(path));
diff --git a/chromecast/base/path_utils_unittest.cc b/chromecast/base/path_utils_unittest.cc
index 618bb0f..9aa4182 100644
--- a/chromecast/base/path_utils_unittest.cc
+++ b/chromecast/base/path_utils_unittest.cc
@@ -14,7 +14,7 @@
std::string GetTestString(int base_dir_key) {
base::FilePath basedir;
- EXPECT_TRUE(PathService::Get(base_dir_key, &basedir));
+ EXPECT_TRUE(base::PathService::Get(base_dir_key, &basedir));
return basedir.value() + "/" + kTestRelPath;
}
diff --git a/chromecast/browser/cast_browser_context.cc b/chromecast/browser/cast_browser_context.cc
index 0aa8205..7dd572b 100644
--- a/chromecast/browser/cast_browser_context.cc
+++ b/chromecast/browser/cast_browser_context.cc
@@ -72,7 +72,7 @@
void CastBrowserContext::InitWhileIOAllowed() {
#if defined(OS_ANDROID)
- CHECK(PathService::Get(base::DIR_ANDROID_APP_DATA, &path_));
+ CHECK(base::PathService::Get(base::DIR_ANDROID_APP_DATA, &path_));
path_ = path_.Append(FILE_PATH_LITERAL("cast_shell"));
if (!base::PathExists(path_))
@@ -82,7 +82,7 @@
// incognito mode. This means that all of the persistent
// data (currently only cookies and local storage) will be
// shared in a single location as defined here.
- CHECK(PathService::Get(DIR_CAST_HOME, &path_));
+ CHECK(base::PathService::Get(DIR_CAST_HOME, &path_));
#endif // defined(OS_ANDROID)
BrowserContext::Initialize(this, path_);
}
diff --git a/chromecast/browser/cast_browser_main_parts.cc b/chromecast/browser/cast_browser_main_parts.cc
index 0741db5..bdba46a0 100644
--- a/chromecast/browser/cast_browser_main_parts.cc
+++ b/chromecast/browser/cast_browser_main_parts.cc
@@ -431,7 +431,7 @@
crash_dumps_dir, kAndroidMinidumpDescriptor));
#else
base::FilePath home_dir;
- CHECK(PathService::Get(DIR_CAST_HOME, &home_dir));
+ CHECK(base::PathService::Get(DIR_CAST_HOME, &home_dir));
if (!base::CreateDirectory(home_dir))
return 1;
#endif
diff --git a/chromecast/browser/cast_content_browser_client.cc b/chromecast/browser/cast_content_browser_client.cc
index 1baf8b2d..7b18381c 100644
--- a/chromecast/browser/cast_content_browser_client.cc
+++ b/chromecast/browser/cast_content_browser_client.cc
@@ -751,7 +751,7 @@
// Let cast shell dump to /tmp. Internal minidump generator code can move it
// to /data/minidumps later, since /data/minidumps is file lock-controlled.
base::FilePath dumps_path;
- PathService::Get(base::DIR_TEMP, &dumps_path);
+ base::PathService::Get(base::DIR_TEMP, &dumps_path);
// Alway set "upload" to false to use our own uploader.
breakpad::CrashHandlerHostLinux* crash_handler =
diff --git a/chromecast/browser/pref_service_helper.cc b/chromecast/browser/pref_service_helper.cc
index 488fbd5..8dd1e9e3 100644
--- a/chromecast/browser/pref_service_helper.cc
+++ b/chromecast/browser/pref_service_helper.cc
@@ -36,7 +36,7 @@
base::FilePath GetConfigPath() {
base::FilePath config_path;
- CHECK(PathService::Get(FILE_CAST_CONFIG, &config_path));
+ CHECK(base::PathService::Get(FILE_CAST_CONFIG, &config_path));
return config_path;
}
diff --git a/chromecast/common/cast_resource_delegate.cc b/chromecast/common/cast_resource_delegate.cc
index 994a426..70328df 100644
--- a/chromecast/common/cast_resource_delegate.cc
+++ b/chromecast/common/cast_resource_delegate.cc
@@ -42,7 +42,7 @@
const base::FilePath& pack_path,
const std::string& locale) {
base::FilePath product_dir;
- if (!PathService::Get(base::DIR_MODULE, &product_dir)) {
+ if (!base::PathService::Get(base::DIR_MODULE, &product_dir)) {
NOTREACHED();
}
return product_dir.
diff --git a/chromecast/crash/linux/minidump_uploader.cc b/chromecast/crash/linux/minidump_uploader.cc
index d3ecef7c..be7717a 100644
--- a/chromecast/crash/linux/minidump_uploader.cc
+++ b/chromecast/crash/linux/minidump_uploader.cc
@@ -46,7 +46,7 @@
std::unique_ptr<PrefService> CreatePrefService() {
base::FilePath prefs_path;
- CHECK(PathService::Get(chromecast::FILE_CAST_CONFIG, &prefs_path));
+ CHECK(base::PathService::Get(chromecast::FILE_CAST_CONFIG, &prefs_path));
VLOG(1) << "Loading prefs from " << prefs_path.value();
PrefRegistrySimple* registry = new PrefRegistrySimple;
diff --git a/chromecast/media/cma/backend/audio_video_pipeline_device_unittest.cc b/chromecast/media/cma/backend/audio_video_pipeline_device_unittest.cc
index eb0632e..337d099 100644
--- a/chromecast/media/cma/backend/audio_video_pipeline_device_unittest.cc
+++ b/chromecast/media/cma/backend/audio_video_pipeline_device_unittest.cc
@@ -84,7 +84,7 @@
base::FilePath GetTestDataFilePath(const std::string& name) {
base::FilePath file_path;
- CHECK(PathService::Get(base::DIR_SOURCE_ROOT, &file_path));
+ CHECK(base::PathService::Get(base::DIR_SOURCE_ROOT, &file_path));
file_path = file_path.Append(FILE_PATH_LITERAL("media"))
.Append(FILE_PATH_LITERAL("test")).Append(FILE_PATH_LITERAL("data"))
diff --git a/chromeos/chromeos_paths.cc b/chromeos/chromeos_paths.cc
index e5c12b9..4c210cf 100644
--- a/chromeos/chromeos_paths.cc
+++ b/chromeos/chromeos_paths.cc
@@ -112,7 +112,7 @@
} // namespace
void RegisterPathProvider() {
- PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
+ base::PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
}
void RegisterStubPathOverrides(const base::FilePath& stubs_dir) {
@@ -120,44 +120,34 @@
// Override these paths on the desktop, so that enrollment and cloud policy
// work and can be tested.
base::FilePath parent = base::MakeAbsoluteFilePath(stubs_dir);
- PathService::Override(
- DIR_USER_POLICY_KEYS,
- parent.AppendASCII("stub_user_policy"));
+ base::PathService::Override(DIR_USER_POLICY_KEYS,
+ parent.AppendASCII("stub_user_policy"));
const bool is_absolute = true;
const bool create = false;
- PathService::OverrideAndCreateIfNeeded(
- FILE_OWNER_KEY,
- parent.AppendASCII("stub_owner.key"),
- is_absolute,
+ base::PathService::OverrideAndCreateIfNeeded(
+ FILE_OWNER_KEY, parent.AppendASCII("stub_owner.key"), is_absolute,
create);
- PathService::OverrideAndCreateIfNeeded(
- FILE_INSTALL_ATTRIBUTES,
- parent.AppendASCII("stub_install_attributes.pb"),
- is_absolute,
+ base::PathService::OverrideAndCreateIfNeeded(
+ FILE_INSTALL_ATTRIBUTES, parent.AppendASCII("stub_install_attributes.pb"),
+ is_absolute, create);
+ base::PathService::OverrideAndCreateIfNeeded(
+ FILE_MACHINE_INFO, parent.AppendASCII("stub_machine-info"), is_absolute,
create);
- PathService::OverrideAndCreateIfNeeded(
- FILE_MACHINE_INFO,
- parent.AppendASCII("stub_machine-info"),
- is_absolute,
- create);
- PathService::OverrideAndCreateIfNeeded(
- FILE_VPD,
- parent.AppendASCII("stub_vpd"),
- is_absolute,
- create);
- PathService::Override(
+ base::PathService::OverrideAndCreateIfNeeded(
+ FILE_VPD, parent.AppendASCII("stub_vpd"), is_absolute, create);
+ base::PathService::Override(
DIR_DEVICE_LOCAL_ACCOUNT_EXTENSIONS,
parent.AppendASCII("stub_device_local_account_extensions"));
- PathService::Override(
+ base::PathService::Override(
DIR_DEVICE_LOCAL_ACCOUNT_EXTERNAL_DATA,
parent.AppendASCII("stub_device_local_account_external_data"));
- PathService::Override(
+ base::PathService::Override(
DIR_DEVICE_LOCAL_ACCOUNT_COMPONENT_POLICY,
parent.AppendASCII("stub_device_local_account_component_policy"));
- PathService::Override(
+ base::PathService::Override(
DIR_DEVICE_EXTENSION_LOCAL_CACHE,
parent.AppendASCII("stub_device_local_extension_cache"));
- PathService::Override(
+ base::PathService::Override(
DIR_SIGNIN_PROFILE_COMPONENT_POLICY,
parent.AppendASCII("stub_signin_profile_component_policy"));
}
diff --git a/chromeos/chromeos_test_utils.cc b/chromeos/chromeos_test_utils.cc
index 8a3456b..6908137 100644
--- a/chromeos/chromeos_test_utils.cc
+++ b/chromeos/chromeos_test_utils.cc
@@ -15,7 +15,7 @@
const std::string& filename,
base::FilePath* data_dir) {
base::FilePath path;
- if (!PathService::Get(base::DIR_SOURCE_ROOT, &path))
+ if (!base::PathService::Get(base::DIR_SOURCE_ROOT, &path))
return false;
path = path.Append(FILE_PATH_LITERAL("chromeos"));
path = path.Append(FILE_PATH_LITERAL("test"));
diff --git a/chromeos/dbus/fake_cryptohome_client.cc b/chromeos/dbus/fake_cryptohome_client.cc
index c16f0a2..28843b19 100644
--- a/chromeos/dbus/fake_cryptohome_client.cc
+++ b/chromeos/dbus/fake_cryptohome_client.cc
@@ -50,8 +50,9 @@
system_salt_(GetStubSystemSalt()),
weak_ptr_factory_(this) {
base::FilePath cache_path;
- locked_ = PathService::Get(chromeos::FILE_INSTALL_ATTRIBUTES, &cache_path) &&
- base::PathExists(cache_path);
+ locked_ =
+ base::PathService::Get(chromeos::FILE_INSTALL_ATTRIBUTES, &cache_path) &&
+ base::PathExists(cache_path);
if (locked_)
LoadInstallAttributes();
}
@@ -262,7 +263,7 @@
// browser is restarted. This is used for ease of development when device
// enrollment is required.
base::FilePath cache_path;
- if (!PathService::Get(chromeos::FILE_INSTALL_ATTRIBUTES, &cache_path))
+ if (!base::PathService::Get(chromeos::FILE_INSTALL_ATTRIBUTES, &cache_path))
return false;
cryptohome::SerializedInstallAttributes install_attrs_proto;
@@ -766,7 +767,7 @@
bool FakeCryptohomeClient::LoadInstallAttributes() {
base::FilePath cache_file;
const bool file_exists =
- PathService::Get(FILE_INSTALL_ATTRIBUTES, &cache_file) &&
+ base::PathService::Get(FILE_INSTALL_ATTRIBUTES, &cache_file) &&
base::PathExists(cache_file);
DCHECK(file_exists);
// Mostly copied from chrome/browser/chromeos/settings/install_attributes.cc.
diff --git a/chromeos/dbus/fake_session_manager_client.cc b/chromeos/dbus/fake_session_manager_client.cc
index 2e963552..35bca46 100644
--- a/chromeos/dbus/fake_session_manager_client.cc
+++ b/chromeos/dbus/fake_session_manager_client.cc
@@ -170,7 +170,7 @@
switch (descriptor.account_type()) {
case login_manager::ACCOUNT_TYPE_DEVICE: {
base::FilePath owner_key_path;
- CHECK(PathService::Get(chromeos::FILE_OWNER_KEY, &owner_key_path));
+ CHECK(base::PathService::Get(chromeos::FILE_OWNER_KEY, &owner_key_path));
if (key_path)
*key_path = owner_key_path;
return owner_key_path.DirName().Append(relative_policy_path);
@@ -180,7 +180,7 @@
case login_manager::ACCOUNT_TYPE_SESSIONLESS_USER:
case login_manager::ACCOUNT_TYPE_DEVICE_LOCAL_ACCOUNT: {
base::FilePath base_path;
- CHECK(PathService::Get(chromeos::DIR_USER_POLICY_KEYS, &base_path));
+ CHECK(base::PathService::Get(chromeos::DIR_USER_POLICY_KEYS, &base_path));
if (key_path) {
*key_path = base_path.Append(relative_policy_path.DirName())
.AppendASCII(kStubPerAccountPolicyKeyFileName);
@@ -502,7 +502,7 @@
StateKeysCallback callback) {
if (policy_storage_ == PolicyStorageType::kOnDisk) {
base::FilePath owner_key_path;
- CHECK(PathService::Get(chromeos::FILE_OWNER_KEY, &owner_key_path));
+ CHECK(base::PathService::Get(chromeos::FILE_OWNER_KEY, &owner_key_path));
const base::FilePath state_keys_path =
owner_key_path.DirName().AppendASCII(kStubStateKeysFileName);
base::PostTaskWithTraitsAndReplyWithResult(
diff --git a/chromeos/services/assistant/platform/file_provider_impl.cc b/chromeos/services/assistant/platform/file_provider_impl.cc
index d7360a4..3077e85 100644
--- a/chromeos/services/assistant/platform/file_provider_impl.cc
+++ b/chromeos/services/assistant/platform/file_provider_impl.cc
@@ -17,7 +17,7 @@
// Get the root path for assistant files.
base::FilePath GetRootPath() {
base::FilePath home_dir;
- CHECK(PathService::Get(base::DIR_HOME, &home_dir));
+ CHECK(base::PathService::Get(base::DIR_HOME, &home_dir));
// Ensures DIR_HOME is overridden after primary user sign-in.
CHECK_NE(base::GetHomeDir(), home_dir);
return home_dir;
diff --git a/chromeos/system/statistics_provider.cc b/chromeos/system/statistics_provider.cc
index a937d97..69c96bb 100644
--- a/chromeos/system/statistics_provider.cc
+++ b/chromeos/system/statistics_provider.cc
@@ -527,7 +527,7 @@
}
base::FilePath machine_info_path;
- PathService::Get(chromeos::FILE_MACHINE_INFO, &machine_info_path);
+ base::PathService::Get(chromeos::FILE_MACHINE_INFO, &machine_info_path);
if (!base::SysInfo::IsRunningOnChromeOS() &&
!base::PathExists(machine_info_path)) {
// Use time value to create an unique stub serial because clashes of the
@@ -546,7 +546,7 @@
}
base::FilePath vpd_path;
- PathService::Get(chromeos::FILE_VPD, &vpd_path);
+ base::PathService::Get(chromeos::FILE_VPD, &vpd_path);
if (!base::SysInfo::IsRunningOnChromeOS() && !base::PathExists(vpd_path)) {
std::string stub_contents = "\"ActivateDate\"=\"2000-01\"\n";
int bytes_written =
diff --git a/cloud_print/common/win/install_utils.cc b/cloud_print/common/win/install_utils.cc
index 955b3ebc..687fe1c 100644
--- a/cloud_print/common/win/install_utils.cc
+++ b/cloud_print/common/win/install_utils.cc
@@ -140,7 +140,7 @@
}
base::FilePath unstall_binary;
- CHECK(PathService::Get(base::FILE_EXE, &unstall_binary));
+ CHECK(base::PathService::Get(base::FILE_EXE, &unstall_binary));
base::CommandLine uninstall_command(unstall_binary);
uninstall_command.AppendSwitch(uninstall_switch);
@@ -186,7 +186,7 @@
void DeleteProgramDir(const std::string& delete_switch) {
base::FilePath installer_source;
- if (!PathService::Get(base::FILE_EXE, &installer_source))
+ if (!base::PathService::Get(base::FILE_EXE, &installer_source))
return;
// Deletes only subdirs of program files.
if (!IsProgramsFilesParent(installer_source))
@@ -206,7 +206,7 @@
bool IsProgramsFilesParent(const base::FilePath& path) {
base::FilePath program_files;
- if (!PathService::Get(base::DIR_PROGRAM_FILESX86, &program_files))
+ if (!base::PathService::Get(base::DIR_PROGRAM_FILESX86, &program_files))
return false;
return program_files.IsParent(path);
}
diff --git a/cloud_print/virtual_driver/win/install/setup.cc b/cloud_print/virtual_driver/win/install/setup.cc
index fc353a1..cdb921e 100644
--- a/cloud_print/virtual_driver/win/install/setup.cc
+++ b/cloud_print/virtual_driver/win/install/setup.cc
@@ -46,7 +46,7 @@
base::FilePath GetSystemPath(const base::string16& binary) {
base::FilePath path;
- if (!PathService::Get(base::DIR_SYSTEM, &path)) {
+ if (!base::PathService::Get(base::DIR_SYSTEM, &path)) {
LOG(ERROR) << "Unable to get system path.";
return path;
}
@@ -59,7 +59,7 @@
base::FilePath path;
// Sysnative will bypass filesystem redirection and give us
// the location of the 64bit system32 from a 32 bit process.
- if (!PathService::Get(base::DIR_WINDOWS, &path)) {
+ if (!base::PathService::Get(base::DIR_WINDOWS, &path)) {
LOG(ERROR) << "Unable to get windows path.";
return path;
}
@@ -380,7 +380,7 @@
*base::CommandLine::ForCurrentProcess();
base::FilePath exe_path;
- if (!PathService::Get(base::DIR_EXE, &exe_path) ||
+ if (!base::PathService::Get(base::DIR_EXE, &exe_path) ||
!base::DirectoryExists(exe_path)) {
return HRESULT_FROM_WIN32(ERROR_PATH_NOT_FOUND);
}
diff --git a/cloud_print/virtual_driver/win/port_monitor/port_monitor.cc b/cloud_print/virtual_driver/win/port_monitor/port_monitor.cc
index c1455b3f..0ea6436 100644
--- a/cloud_print/virtual_driver/win/port_monitor/port_monitor.cc
+++ b/cloud_print/virtual_driver/win/port_monitor/port_monitor.cc
@@ -278,7 +278,7 @@
// Consider using the shell to invoke the default browser instead of hardcoded
// reference to IE which might not be available on the system.
base::FilePath ie_path;
- PathService::Get(base::DIR_PROGRAM_FILESX86, &ie_path);
+ base::PathService::Get(base::DIR_PROGRAM_FILESX86, &ie_path);
ie_path = ie_path.Append(kIePath);
base::CommandLine command_line(ie_path);
command_line.AppendArg(kChromeInstallUrl);
@@ -670,7 +670,7 @@
// Unit tests set up their own AtExitManager
monitor_data->at_exit_manager.reset(new base::AtExitManager());
// Single spooler.exe handles verbose users.
- PathService::DisableCache();
+ base::PathService::DisableCache();
}
return &cloud_print::g_monitor_2;
}
diff --git a/cloud_print/virtual_driver/win/port_monitor/port_monitor_unittest.cc b/cloud_print/virtual_driver/win/port_monitor/port_monitor_unittest.cc
index 3ef126c..4cc9e55 100644
--- a/cloud_print/virtual_driver/win/port_monitor/port_monitor_unittest.cc
+++ b/cloud_print/virtual_driver/win/port_monitor/port_monitor_unittest.cc
@@ -46,12 +46,12 @@
KEY_ALL_ACCESS);
base::FilePath path;
- PathService::Get(base::DIR_LOCAL_APP_DATA, &path);
+ base::PathService::Get(base::DIR_LOCAL_APP_DATA, &path);
path = path.Append(kAlternateChromeExePath);
ASSERT_EQ(ERROR_SUCCESS, key.WriteValue(cloud_print::kChromeExePathRegValue,
path.value().c_str()));
base::FilePath temp;
- PathService::Get(base::DIR_TEMP, &temp);
+ base::PathService::Get(base::DIR_TEMP, &temp);
// Write any dir here.
ASSERT_EQ(ERROR_SUCCESS,
key.WriteValue(cloud_print::kChromeProfilePathRegValue,
@@ -71,7 +71,7 @@
virtual void CreateTempChromeExeFiles() {
base::FilePath path;
- PathService::Get(base::DIR_LOCAL_APP_DATA, &path);
+ base::PathService::Get(base::DIR_LOCAL_APP_DATA, &path);
base::FilePath main_path = path.Append(kChromeExePath);
ASSERT_TRUE(base::CreateDirectory(main_path));
base::FilePath alternate_path = path.Append(kAlternateChromeExePath);
@@ -80,10 +80,10 @@
virtual void DeleteTempChromeExeFiles() {
base::FilePath path;
- PathService::Get(base::DIR_LOCAL_APP_DATA, &path);
+ base::PathService::Get(base::DIR_LOCAL_APP_DATA, &path);
base::FilePath main_path = path.Append(kChromeExePath);
ASSERT_TRUE(base::DeleteFile(main_path, true));
- PathService::Get(base::DIR_LOCAL_APP_DATA, &path);
+ base::PathService::Get(base::DIR_LOCAL_APP_DATA, &path);
base::FilePath alternate_path = path.Append(kAlternateChromeExePath);
ASSERT_TRUE(base::DeleteFile(alternate_path, true));
}
@@ -124,7 +124,7 @@
base::FilePath data_path = cloud_print::GetChromeProfilePath();
EXPECT_FALSE(data_path.empty());
base::FilePath temp;
- PathService::Get(base::DIR_TEMP, &temp);
+ base::PathService::Get(base::DIR_TEMP, &temp);
EXPECT_EQ(data_path, temp);
EXPECT_TRUE(base::DirectoryExists(data_path));
DeleteChromeExeRegistry();
diff --git a/components/component_updater/component_installer_unittest.cc b/components/component_updater/component_installer_unittest.cc
index db468e9..daf2ff73 100644
--- a/components/component_updater/component_installer_unittest.cc
+++ b/components/component_updater/component_installer_unittest.cc
@@ -339,7 +339,7 @@
// Test the precondition that DIR_COMPONENT_USER is not registered with
// the path service.
base::FilePath base_dir;
- EXPECT_FALSE(PathService::Get(DIR_COMPONENT_USER, &base_dir));
+ EXPECT_FALSE(base::PathService::Get(DIR_COMPONENT_USER, &base_dir));
// Calling |Install| fails since DIR_COMPONENT_USER does not exist.
installer->Install(
diff --git a/components/nacl/zygote/nacl_fork_delegate_linux.cc b/components/nacl/zygote/nacl_fork_delegate_linux.cc
index 30c1c0c..afd6212 100644
--- a/components/nacl/zygote/nacl_fork_delegate_linux.cc
+++ b/components/nacl/zygote/nacl_fork_delegate_linux.cc
@@ -206,8 +206,8 @@
&helper_exe)) {
status_ = kNaClHelperMissing;
} else if (use_nacl_bootstrap &&
- !PathService::Get(nacl::FILE_NACL_HELPER_BOOTSTRAP,
- &helper_bootstrap_exe)) {
+ !base::PathService::Get(nacl::FILE_NACL_HELPER_BOOTSTRAP,
+ &helper_bootstrap_exe)) {
status_ = kNaClHelperBootstrapMissing;
} else {
base::CommandLine::StringVector argv_to_launch;
diff --git a/components/policy/core/common/policy_loader_win.cc b/components/policy/core/common/policy_loader_win.cc
index 3047537..1e3d2e2a 100644
--- a/components/policy/core/common/policy_loader_win.cc
+++ b/components/policy/core/common/policy_loader_win.cc
@@ -215,7 +215,7 @@
bool got_function_addresses = false;
// Use an absolute path to load the DLL to avoid DLL preloading attacks.
base::FilePath path;
- if (PathService::Get(base::DIR_SYSTEM, &path)) {
+ if (base::PathService::Get(base::DIR_SYSTEM, &path)) {
HINSTANCE net_api_library = ::LoadLibraryEx(
path.Append(FILE_PATH_LITERAL("netapi32.dll")).value().c_str(), nullptr,
LOAD_WITH_ALTERED_SEARCH_PATH);
diff --git a/content/browser/frame_host/blocked_scheme_navigation_browsertest.cc b/content/browser/frame_host/blocked_scheme_navigation_browsertest.cc
index 78b63d7..46f9453 100644
--- a/content/browser/frame_host/blocked_scheme_navigation_browsertest.cc
+++ b/content/browser/frame_host/blocked_scheme_navigation_browsertest.cc
@@ -185,7 +185,7 @@
ASSERT_TRUE(embedded_test_server()->Start());
base::FilePath path;
- ASSERT_TRUE(PathService::Get(content::DIR_TEST_DATA, &path));
+ ASSERT_TRUE(base::PathService::Get(content::DIR_TEST_DATA, &path));
path = path.AppendASCII("data_url_navigations.html");
ASSERT_TRUE(base::PathExists(path));
diff --git a/courgette/base_test_unittest.cc b/courgette/base_test_unittest.cc
index a5537b6..972105bf 100644
--- a/courgette/base_test_unittest.cc
+++ b/courgette/base_test_unittest.cc
@@ -8,7 +8,7 @@
#include "base/path_service.h"
void BaseTest::SetUp() {
- ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &test_dir_));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &test_dir_));
test_dir_ = test_dir_.AppendASCII("courgette");
test_dir_ = test_dir_.AppendASCII("testdata");
}
diff --git a/crypto/nss_util.cc b/crypto/nss_util.cc
index 6fc56ba..cc6b7df 100644
--- a/crypto/nss_util.cc
+++ b/crypto/nss_util.cc
@@ -73,7 +73,7 @@
#if !defined(OS_CHROMEOS)
base::FilePath GetDefaultConfigDirectory() {
base::FilePath dir;
- PathService::Get(base::DIR_HOME, &dir);
+ base::PathService::Get(base::DIR_HOME, &dir);
if (dir.empty()) {
LOG(ERROR) << "Failed to get home directory.";
return dir;
diff --git a/device/test/usb_test_gadget_impl.cc b/device/test/usb_test_gadget_impl.cc
index 50d2fbc..a9032a2 100644
--- a/device/test/usb_test_gadget_impl.cc
+++ b/device/test/usb_test_gadget_impl.cc
@@ -112,7 +112,7 @@
bool ReadLocalVersion(std::string* version) {
base::FilePath file_path;
- CHECK(PathService::Get(base::DIR_EXE, &file_path));
+ CHECK(base::PathService::Get(base::DIR_EXE, &file_path));
file_path = file_path.AppendASCII("usb_gadget.zip.md5");
return ReadFile(file_path, version);
@@ -120,7 +120,7 @@
bool ReadLocalPackage(std::string* package) {
base::FilePath file_path;
- CHECK(PathService::Get(base::DIR_EXE, &file_path));
+ CHECK(base::PathService::Get(base::DIR_EXE, &file_path));
file_path = file_path.AppendASCII("usb_gadget.zip");
return ReadFile(file_path, package);
diff --git a/gin/shell/gin_shell_unittest.cc b/gin/shell/gin_shell_unittest.cc
index ce905351..5c7dd0cd 100644
--- a/gin/shell/gin_shell_unittest.cc
+++ b/gin/shell/gin_shell_unittest.cc
@@ -11,7 +11,7 @@
base::FilePath GinShellPath() {
base::FilePath dir;
- PathService::Get(base::DIR_EXE, &dir);
+ base::PathService::Get(base::DIR_EXE, &dir);
#if defined(OS_WIN)
return dir.AppendASCII("gin_shell.exe");
#else
@@ -21,7 +21,7 @@
base::FilePath HelloWorldPath() {
base::FilePath path;
- PathService::Get(base::DIR_SOURCE_ROOT, &path);
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &path);
return path
.AppendASCII("gin")
.AppendASCII("shell")
diff --git a/gin/v8_initializer.cc b/gin/v8_initializer.cc
index 02d4b1c..be2b9149 100644
--- a/gin/v8_initializer.cc
+++ b/gin/v8_initializer.cc
@@ -114,7 +114,7 @@
*path_out = base::mac::PathForFrameworkBundleResource(natives_file_name);
#else
base::FilePath data_path;
- bool r = PathService::Get(base::DIR_ASSETS, &data_path);
+ bool r = base::PathService::Get(base::DIR_ASSETS, &data_path);
DCHECK(r);
*path_out = data_path.AppendASCII(file_name);
#endif
diff --git a/google_apis/drive/test_util.cc b/google_apis/drive/test_util.cc
index cb3767c..3d95506 100644
--- a/google_apis/drive/test_util.cc
+++ b/google_apis/drive/test_util.cc
@@ -34,7 +34,7 @@
base::FilePath GetTestFilePath(const std::string& relative_path) {
base::FilePath path;
- if (!PathService::Get(base::DIR_SOURCE_ROOT, &path))
+ if (!base::PathService::Get(base::DIR_SOURCE_ROOT, &path))
return base::FilePath();
path = path.AppendASCII("google_apis")
.AppendASCII("test")
diff --git a/google_apis/gaia/fake_gaia.cc b/google_apis/gaia/fake_gaia.cc
index 1e76b22..4c99e16 100644
--- a/google_apis/gaia/fake_gaia.cc
+++ b/google_apis/gaia/fake_gaia.cc
@@ -158,7 +158,7 @@
FakeGaia::FakeGaia() : issue_oauth_code_cookie_(false) {
base::FilePath source_root_dir;
- PathService::Get(base::DIR_SOURCE_ROOT, &source_root_dir);
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &source_root_dir);
CHECK(base::ReadFileToString(
source_root_dir.Append(base::FilePath(kServiceLogin)),
&service_login_response_));
diff --git a/gpu/gles2_conform_support/gles2_conform_test.cc b/gpu/gles2_conform_support/gles2_conform_test.cc
index ff1bafe..380df33 100644
--- a/gpu/gles2_conform_support/gles2_conform_test.cc
+++ b/gpu/gles2_conform_support/gles2_conform_test.cc
@@ -37,7 +37,7 @@
bool RunGLES2ConformTest(const char* path) {
// Load test expectations, and return early if a test is marked as FAIL.
base::FilePath src_path;
- PathService::Get(base::DIR_SOURCE_ROOT, &src_path);
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &src_path);
base::FilePath test_expectations_path =
src_path.Append(FILE_PATH_LITERAL("gpu")).
Append(FILE_PATH_LITERAL("gles2_conform_support")).
@@ -101,7 +101,7 @@
}
base::FilePath test_path;
- PathService::Get(base::DIR_EXE, &test_path);
+ base::PathService::Get(base::DIR_EXE, &test_path);
base::FilePath program(test_path.Append(FILE_PATH_LITERAL(
"gles2_conform_test_windowless")));
diff --git a/gpu/khronos_glcts_support/khronos_glcts_test.cc b/gpu/khronos_glcts_support/khronos_glcts_test.cc
index d75e824..5662972 100644
--- a/gpu/khronos_glcts_support/khronos_glcts_test.cc
+++ b/gpu/khronos_glcts_support/khronos_glcts_test.cc
@@ -27,7 +27,7 @@
bool RunKhronosGLCTSTest(const char* test_name) {
// Load test expectations, and return early if a test is marked as FAIL.
base::FilePath src_path;
- PathService::Get(base::DIR_SOURCE_ROOT, &src_path);
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &src_path);
base::FilePath test_expectations_path =
src_path.Append(FILE_PATH_LITERAL("gpu")).
Append(FILE_PATH_LITERAL("khronos_glcts_support")).
@@ -61,7 +61,7 @@
}
base::FilePath test_path;
- PathService::Get(base::DIR_EXE, &test_path);
+ base::PathService::Get(base::DIR_EXE, &test_path);
base::FilePath archive(test_path.Append(FILE_PATH_LITERAL(
"khronos_glcts_data")));
base::FilePath program(test_path.Append(FILE_PATH_LITERAL(
diff --git a/headless/lib/browser/headless_browser_context_impl.cc b/headless/lib/browser/headless_browser_context_impl.cc
index 5ca136f..9666b81e 100644
--- a/headless/lib/browser/headless_browser_context_impl.cc
+++ b/headless/lib/browser/headless_browser_context_impl.cc
@@ -210,7 +210,7 @@
if (!context_options_->user_data_dir().empty()) {
path_ = context_options_->user_data_dir().Append(kDefaultProfileName);
} else {
- PathService::Get(base::DIR_EXE, &path_);
+ base::PathService::Get(base::DIR_EXE, &path_);
}
BrowserContext::Initialize(this, path_);
}
diff --git a/headless/lib/browser/headless_content_browser_client.cc b/headless/lib/browser/headless_content_browser_client.cc
index 200a1d0..1381664 100644
--- a/headless/lib/browser/headless_content_browser_client.cc
+++ b/headless/lib/browser/headless_content_browser_client.cc
@@ -62,7 +62,7 @@
const HeadlessBrowser::Options& options) {
base::FilePath dumps_path = options.crash_dumps_dir;
if (dumps_path.empty()) {
- bool ok = PathService::Get(base::DIR_MODULE, &dumps_path);
+ bool ok = base::PathService::Get(base::DIR_MODULE, &dumps_path);
DCHECK(ok);
}
diff --git a/headless/lib/headless_content_main_delegate.cc b/headless/lib/headless_content_main_delegate.cc
index dae3991..1c96f77a 100644
--- a/headless/lib/headless_content_main_delegate.cc
+++ b/headless/lib/headless_content_main_delegate.cc
@@ -173,7 +173,7 @@
// Otherwise we log to where the executable is.
if (log_path.empty()) {
- if (PathService::Get(base::DIR_MODULE, &log_path)) {
+ if (base::PathService::Get(base::DIR_MODULE, &log_path)) {
log_path = log_path.Append(log_filename);
} else {
log_path = log_filename;
@@ -314,7 +314,7 @@
#else
base::FilePath dir_module;
- bool result = PathService::Get(base::DIR_MODULE, &dir_module);
+ bool result = base::PathService::Get(base::DIR_MODULE, &dir_module);
DCHECK(result);
// Try loading the headless library pak file first. If it doesn't exist (i.e.,
diff --git a/headless/test/headless_browser_test.cc b/headless/test/headless_browser_test.cc
index 52a900e..3fb0912 100644
--- a/headless/test/headless_browser_test.cc
+++ b/headless/test/headless_browser_test.cc
@@ -131,9 +131,9 @@
// On Mac the source root is not set properly. We override it by assuming
// that is two directories up from the execution test file.
base::FilePath dir_exe_path;
- CHECK(PathService::Get(base::DIR_EXE, &dir_exe_path));
+ CHECK(base::PathService::Get(base::DIR_EXE, &dir_exe_path));
dir_exe_path = dir_exe_path.Append("../../");
- CHECK(PathService::Override(base::DIR_SOURCE_ROOT, dir_exe_path));
+ CHECK(base::PathService::Override(base::DIR_SOURCE_ROOT, dir_exe_path));
#endif // defined(OS_MACOSX)
base::FilePath headless_test_data(FILE_PATH_LITERAL("headless/test/data"));
CreateTestServer(headless_test_data);
diff --git a/headless/test/headless_js_bindings_browsertest.cc b/headless/test/headless_js_bindings_browsertest.cc
index cafa8830..295f722 100644
--- a/headless/test/headless_js_bindings_browsertest.cc
+++ b/headless/test/headless_js_bindings_browsertest.cc
@@ -54,7 +54,7 @@
void SetUpOnMainThread() override {
base::ThreadRestrictions::SetIOAllowed(true);
base::FilePath pak_path;
- ASSERT_TRUE(PathService::Get(base::DIR_MODULE, &pak_path));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_MODULE, &pak_path));
pak_path = pak_path.AppendASCII("headless_browser_tests.pak");
ui::ResourceBundle::GetSharedInstance().AddDataPackFromPath(
pak_path, ui::SCALE_FACTOR_NONE);
diff --git a/mash/test/mash_test_suite.cc b/mash/test/mash_test_suite.cc
index a5160d5..1649ca7 100644
--- a/mash/test/mash_test_suite.cc
+++ b/mash/test/mash_test_suite.cc
@@ -46,7 +46,7 @@
// Load ash mus strings and resources; not 'common' (Chrome) resources.
base::FilePath resources;
- PathService::Get(base::DIR_MODULE, &resources);
+ base::PathService::Get(base::DIR_MODULE, &resources);
resources = resources.Append(FILE_PATH_LITERAL("ash_service_resources.pak"));
ui::ResourceBundle::InitSharedInstanceWithPakPath(resources);
diff --git a/media/audio/android/audio_android_unittest.cc b/media/audio/android/audio_android_unittest.cc
index 92eb8b6..80a35d5 100644
--- a/media/audio/android/audio_android_unittest.cc
+++ b/media/audio/android/audio_android_unittest.cc
@@ -249,7 +249,7 @@
// Open up the binary file which will be written to in the destructor.
base::FilePath file_path;
- EXPECT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &file_path));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &file_path));
file_path = file_path.AppendASCII(file_name.c_str());
binary_file_ = base::OpenFile(file_path, "wb");
DLOG_IF(ERROR, !binary_file_) << "Failed to open binary PCM data file.";
diff --git a/media/audio/audio_low_latency_input_output_unittest.cc b/media/audio/audio_low_latency_input_output_unittest.cc
index c264b5b1..a3355e75 100644
--- a/media/audio/audio_low_latency_input_output_unittest.cc
+++ b/media/audio/audio_low_latency_input_output_unittest.cc
@@ -126,7 +126,7 @@
// Get complete file path to output file in the directory containing
// media_unittests.exe. Example: src/build/Debug/audio_delay_values_ms.txt.
base::FilePath file_name;
- EXPECT_TRUE(PathService::Get(base::DIR_EXE, &file_name));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_EXE, &file_name));
file_name = file_name.AppendASCII(kDelayValuesFileName);
FILE* text_file = base::OpenFile(file_name, "wt");
diff --git a/media/audio/win/audio_low_latency_input_win_unittest.cc b/media/audio/win/audio_low_latency_input_win_unittest.cc
index 2aeaac3..299f260 100644
--- a/media/audio/win/audio_low_latency_input_win_unittest.cc
+++ b/media/audio/win/audio_low_latency_input_win_unittest.cc
@@ -106,7 +106,7 @@
explicit WriteToFileAudioSink(const char* file_name)
: buffer_(0, kMaxBufferSize), bytes_to_write_(0) {
base::FilePath file_path;
- EXPECT_TRUE(PathService::Get(base::DIR_EXE, &file_path));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_EXE, &file_path));
file_path = file_path.AppendASCII(file_name);
binary_file_ = base::OpenFile(file_path, "wb");
DLOG_IF(ERROR, !binary_file_) << "Failed to open binary PCM data file.";
diff --git a/media/audio/win/audio_low_latency_output_win_unittest.cc b/media/audio/win/audio_low_latency_output_win_unittest.cc
index 693caf3..9c7ea43a 100644
--- a/media/audio/win/audio_low_latency_output_win_unittest.cc
+++ b/media/audio/win/audio_low_latency_output_win_unittest.cc
@@ -93,7 +93,7 @@
// Get complete file path to output file in directory containing
// media_unittests.exe.
base::FilePath file_name;
- EXPECT_TRUE(PathService::Get(base::DIR_EXE, &file_name));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_EXE, &file_name));
file_name = file_name.AppendASCII(kDeltaTimeMsFileName);
EXPECT_TRUE(!text_file_);
diff --git a/media/base/test_data_util.cc b/media/base/test_data_util.cc
index b62990d..6ca9aa9 100644
--- a/media/base/test_data_util.cc
+++ b/media/base/test_data_util.cc
@@ -43,7 +43,7 @@
base::FilePath GetTestDataFilePath(const std::string& name) {
base::FilePath file_path;
- CHECK(PathService::Get(base::DIR_SOURCE_ROOT, &file_path));
+ CHECK(base::PathService::Get(base::DIR_SOURCE_ROOT, &file_path));
return file_path.Append(GetTestDataPath()).AppendASCII(name);
}
diff --git a/media/cast/test/simulator.cc b/media/cast/test/simulator.cc
index 4c180bc..22458377d 100644
--- a/media/cast/test/simulator.cc
+++ b/media/cast/test/simulator.cc
@@ -703,7 +703,7 @@
const base::CommandLine* cmd = base::CommandLine::ForCurrentProcess();
base::FilePath media_path = cmd->GetSwitchValuePath(media::cast::kLibDir);
if (media_path.empty()) {
- if (!PathService::Get(base::DIR_MODULE, &media_path)) {
+ if (!base::PathService::Get(base::DIR_MODULE, &media_path)) {
LOG(ERROR) << "Failed to load FFmpeg.";
return 1;
}
diff --git a/media/cdm/external_clear_key_test_helper.cc b/media/cdm/external_clear_key_test_helper.cc
index 8c9cea4..53fb6023 100644
--- a/media/cdm/external_clear_key_test_helper.cc
+++ b/media/cdm/external_clear_key_test_helper.cc
@@ -33,7 +33,7 @@
// Determine the location of the CDM. It is expected to be in the same
// directory as the current module.
base::FilePath cdm_base_path;
- ASSERT_TRUE(PathService::Get(base::DIR_MODULE, &cdm_base_path));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_MODULE, &cdm_base_path));
cdm_base_path = cdm_base_path.Append(
GetPlatformSpecificDirectory(kClearKeyCdmBaseDirectory));
library_path_ = cdm_base_path.AppendASCII(
diff --git a/media/filters/ffmpeg_demuxer_unittest.cc b/media/filters/ffmpeg_demuxer_unittest.cc
index 253d889..c562b27 100644
--- a/media/filters/ffmpeg_demuxer_unittest.cc
+++ b/media/filters/ffmpeg_demuxer_unittest.cc
@@ -320,7 +320,7 @@
CHECK(!data_source_);
base::FilePath file_path;
- EXPECT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &file_path));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &file_path));
file_path = file_path.Append(FILE_PATH_LITERAL("media"))
.Append(FILE_PATH_LITERAL("test"))
diff --git a/media/filters/file_data_source_unittest.cc b/media/filters/file_data_source_unittest.cc
index ee107a1..15398893 100644
--- a/media/filters/file_data_source_unittest.cc
+++ b/media/filters/file_data_source_unittest.cc
@@ -38,7 +38,7 @@
// chars so just return the string from the base::FilePath.
base::FilePath TestFileURL() {
base::FilePath data_dir;
- EXPECT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &data_dir));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &data_dir));
data_dir = data_dir.Append(FILE_PATH_LITERAL("media"))
.Append(FILE_PATH_LITERAL("test"))
.Append(FILE_PATH_LITERAL("data"))
diff --git a/media/filters/jpeg_parser_unittest.cc b/media/filters/jpeg_parser_unittest.cc
index 6fbea1a..ac3a2ddd 100644
--- a/media/filters/jpeg_parser_unittest.cc
+++ b/media/filters/jpeg_parser_unittest.cc
@@ -15,7 +15,7 @@
TEST(JpegParserTest, Parsing) {
base::FilePath data_dir;
- ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &data_dir));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &data_dir));
// This sample frame is captured from Chromebook Pixel
base::FilePath file_path = data_dir.AppendASCII("media")
@@ -83,7 +83,7 @@
TEST(JpegParserTest, CodedSizeNotEqualVisibleSize) {
base::FilePath data_dir;
- ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &data_dir));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &data_dir));
base::FilePath file_path = data_dir.AppendASCII("media")
.AppendASCII("test")
diff --git a/media/gpu/windows/dxva_video_decode_accelerator_win.cc b/media/gpu/windows/dxva_video_decode_accelerator_win.cc
index d8f1898..7d036b2 100644
--- a/media/gpu/windows/dxva_video_decode_accelerator_win.cc
+++ b/media/gpu/windows/dxva_video_decode_accelerator_win.cc
@@ -1618,7 +1618,7 @@
enable_accelerated_vpx_decode_ & gpu::GpuPreferences::VPX_VENDOR_AMD &&
profile == VP9PROFILE_PROFILE0) {
base::FilePath dll_path;
- if (PathService::Get(program_files_key, &dll_path)) {
+ if (base::PathService::Get(program_files_key, &dll_path)) {
codec_ = media::kCodecVP9;
dll_path = dll_path.Append(kAMDVPXDecoderDLLPath);
dll_path = dll_path.Append(kAMDVP9DecoderDLLName);
diff --git a/mojo/edk/test/test_support_impl.cc b/mojo/edk/test/test_support_impl.cc
index 25684e4..50a5353 100644
--- a/mojo/edk/test/test_support_impl.cc
+++ b/mojo/edk/test/test_support_impl.cc
@@ -27,7 +27,7 @@
base::FilePath ResolveSourceRootRelativePath(const char* relative_path) {
base::FilePath path;
- if (!PathService::Get(base::DIR_SOURCE_ROOT, &path))
+ if (!base::PathService::Get(base::DIR_SOURCE_ROOT, &path))
return base::FilePath();
for (const base::StringPiece& component : base::SplitStringPiece(
diff --git a/pdf/pdfium/findtext_unittest.cc b/pdf/pdfium/findtext_unittest.cc
index 2642d6e..d491e8e 100644
--- a/pdf/pdfium/findtext_unittest.cc
+++ b/pdf/pdfium/findtext_unittest.cc
@@ -22,7 +22,7 @@
public:
explicit TestDocumentLoader(Client* client) : client_(client) {
base::FilePath pdf_path;
- CHECK(PathService::Get(base::DIR_SOURCE_ROOT, &pdf_path));
+ CHECK(base::PathService::Get(base::DIR_SOURCE_ROOT, &pdf_path));
pdf_path = pdf_path.Append(FILE_PATH_LITERAL("pdf"))
.Append(FILE_PATH_LITERAL("test"))
.Append(FILE_PATH_LITERAL("data"))
diff --git a/printing/backend/cups_helper.cc b/printing/backend/cups_helper.cc
index d352ccf8c..20b1c85 100644
--- a/printing/backend/cups_helper.cc
+++ b/printing/backend/cups_helper.cc
@@ -119,7 +119,7 @@
std::vector<base::FilePath> file_locations;
file_locations.push_back(base::FilePath(kSystemLpOptionPath));
base::FilePath homedir;
- PathService::Get(base::DIR_HOME, &homedir);
+ base::PathService::Get(base::DIR_HOME, &homedir);
file_locations.push_back(base::FilePath(homedir.Append(kUserLpOptionPath)));
for (const base::FilePath& location : file_locations) {
diff --git a/printing/emf_win_unittest.cc b/printing/emf_win_unittest.cc
index e98b628a..9372af1 100644
--- a/printing/emf_win_unittest.cc
+++ b/printing/emf_win_unittest.cc
@@ -92,7 +92,7 @@
EXPECT_EQ(PrintingContext::OK, context.InitWithSettingsForTest(settings));
base::FilePath emf_file;
- EXPECT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &emf_file));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &emf_file));
emf_file = emf_file.Append(FILE_PATH_LITERAL("printing"))
.Append(FILE_PATH_LITERAL("test"))
.Append(FILE_PATH_LITERAL("data"))
diff --git a/remoting/host/branding.cc b/remoting/host/branding.cc
index 45c0804..83fd0822 100644
--- a/remoting/host/branding.cc
+++ b/remoting/host/branding.cc
@@ -43,11 +43,11 @@
base::FilePath app_data_dir;
#if defined(OS_WIN)
- PathService::Get(base::DIR_COMMON_APP_DATA, &app_data_dir);
+ base::PathService::Get(base::DIR_COMMON_APP_DATA, &app_data_dir);
#elif defined(OS_MACOSX)
- PathService::Get(base::DIR_APP_DATA, &app_data_dir);
+ base::PathService::Get(base::DIR_APP_DATA, &app_data_dir);
#else
- PathService::Get(base::DIR_HOME, &app_data_dir);
+ base::PathService::Get(base::DIR_HOME, &app_data_dir);
#endif
return app_data_dir.Append(kConfigDir);
diff --git a/remoting/host/file_transfer_message_handler.cc b/remoting/host/file_transfer_message_handler.cc
index f659a292..aea05128 100644
--- a/remoting/host/file_transfer_message_handler.cc
+++ b/remoting/host/file_transfer_message_handler.cc
@@ -103,8 +103,9 @@
}
base::FilePath target_directory;
- if (!PathService::Get(base::DIR_USER_DESKTOP, &target_directory)) {
- CancelAndSendError("Failed to get DIR_USER_DESKTOP from PathService::Get");
+ if (!base::PathService::Get(base::DIR_USER_DESKTOP, &target_directory)) {
+ CancelAndSendError(
+ "Failed to get DIR_USER_DESKTOP from base::PathService::Get");
return;
}
diff --git a/remoting/host/ipc_constants.cc b/remoting/host/ipc_constants.cc
index 84b24a7..d0aaede 100644
--- a/remoting/host/ipc_constants.cc
+++ b/remoting/host/ipc_constants.cc
@@ -20,7 +20,7 @@
bool GetInstalledBinaryPath(const base::FilePath::StringType& binary,
base::FilePath* full_path) {
base::FilePath dir_path;
- if (!PathService::Get(base::DIR_EXE, &dir_path)) {
+ if (!base::PathService::Get(base::DIR_EXE, &dir_path)) {
LOG(ERROR) << "Failed to get the executable file name.";
return false;
}
diff --git a/remoting/host/resources_linux.cc b/remoting/host/resources_linux.cc
index 4dc96744..021c73b 100644
--- a/remoting/host/resources_linux.cc
+++ b/remoting/host/resources_linux.cc
@@ -28,8 +28,8 @@
// Point DIR_LOCALES to 'remoting_locales'.
base::FilePath path = base::FilePath(info.dli_fname).DirName();
- PathService::Override(ui::DIR_LOCALES,
- path.AppendASCII(kLocaleResourcesDirName));
+ base::PathService::Override(ui::DIR_LOCALES,
+ path.AppendASCII(kLocaleResourcesDirName));
ui::ResourceBundle::InitSharedInstanceWithLocale(
pref_locale, NULL, ui::ResourceBundle::DO_NOT_LOAD_COMMON_RESOURCES);
diff --git a/remoting/host/setup/daemon_controller_delegate_linux.cc b/remoting/host/setup/daemon_controller_delegate_linux.cc
index 80212f1..20962c72 100644
--- a/remoting/host/setup/daemon_controller_delegate_linux.cc
+++ b/remoting/host/setup/daemon_controller_delegate_linux.cc
@@ -53,14 +53,14 @@
std::string filename =
"host#" + base::MD5String(net::GetHostName()) + ".json";
base::FilePath homedir;
- PathService::Get(base::DIR_HOME, &homedir);
+ base::PathService::Get(base::DIR_HOME, &homedir);
return homedir.Append(".config/chrome-remote-desktop").Append(filename);
}
bool GetScriptPath(base::FilePath* result) {
#ifndef NDEBUG
base::FilePath out_dir;
- PathService::Get(base::DIR_EXE, &out_dir);
+ base::PathService::Get(base::DIR_EXE, &out_dir);
base::FilePath dev_exe = out_dir.AppendASCII(kDaemonDevScript);
if (access(dev_exe.value().c_str(), X_OK) == 0) {
*result = dev_exe;
diff --git a/remoting/test/frame_generator_util.cc b/remoting/test/frame_generator_util.cc
index f8231fa6..69e5f6c 100644
--- a/remoting/test/frame_generator_util.cc
+++ b/remoting/test/frame_generator_util.cc
@@ -36,7 +36,7 @@
std::unique_ptr<webrtc::DesktopFrame> LoadDesktopFrameFromPng(
const char* name) {
base::FilePath file_path;
- PathService::Get(base::DIR_SOURCE_ROOT, &file_path);
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &file_path);
file_path = file_path.AppendASCII("remoting");
file_path = file_path.AppendASCII("test");
file_path = file_path.AppendASCII("data");
diff --git a/rlz/chromeos/lib/rlz_value_store_chromeos.cc b/rlz/chromeos/lib/rlz_value_store_chromeos.cc
index cab3e0c..04a6a0d 100644
--- a/rlz/chromeos/lib/rlz_value_store_chromeos.cc
+++ b/rlz/chromeos/lib/rlz_value_store_chromeos.cc
@@ -52,7 +52,7 @@
base::FilePath GetRlzStorePathCommon() {
base::FilePath homedir;
- PathService::Get(base::DIR_HOME, &homedir);
+ base::PathService::Get(base::DIR_HOME, &homedir);
return g_testing_rlz_store_path.Get().empty()
? homedir
: g_testing_rlz_store_path.Get();
diff --git a/sandbox/linux/suid/client/setuid_sandbox_host.cc b/sandbox/linux/suid/client/setuid_sandbox_host.cc
index 89836aa..6096c3bc 100644
--- a/sandbox/linux/suid/client/setuid_sandbox_host.cc
+++ b/sandbox/linux/suid/client/setuid_sandbox_host.cc
@@ -120,7 +120,7 @@
base::FilePath SetuidSandboxHost::GetSandboxBinaryPath() {
base::FilePath sandbox_binary;
base::FilePath exe_dir;
- if (PathService::Get(base::DIR_EXE, &exe_dir)) {
+ if (base::PathService::Get(base::DIR_EXE, &exe_dir)) {
base::FilePath sandbox_candidate = exe_dir.AppendASCII("chrome-sandbox");
if (base::PathExists(sandbox_candidate))
sandbox_binary = sandbox_candidate;
diff --git a/sandbox/win/src/address_sanitizer_test.cc b/sandbox/win/src/address_sanitizer_test.cc
index ae1590a..3803078 100644
--- a/sandbox/win/src/address_sanitizer_test.cc
+++ b/sandbox/win/src/address_sanitizer_test.cc
@@ -78,7 +78,7 @@
ASSERT_EQ(SBOX_ALL_OK, runner.GetPolicy()->SetStderrHandle(tmp_handle.Get()));
base::FilePath exe;
- ASSERT_TRUE(PathService::Get(base::FILE_EXE, &exe));
+ ASSERT_TRUE(base::PathService::Get(base::FILE_EXE, &exe));
base::FilePath pdb_path = exe.DirName().Append(L"*.pdb");
ASSERT_TRUE(runner.AddFsRule(TargetPolicy::FILES_ALLOW_READONLY,
pdb_path.value().c_str()));
diff --git a/sandbox/win/src/process_mitigations_unittest.cc b/sandbox/win/src/process_mitigations_unittest.cc
index e344a1f..e13b22a 100644
--- a/sandbox/win/src/process_mitigations_unittest.cc
+++ b/sandbox/win/src/process_mitigations_unittest.cc
@@ -95,10 +95,10 @@
// Choose the appropriate DLL and make sure the sandbox allows access to it.
base::FilePath dll_path;
if (use_ms_signed_binary) {
- EXPECT_TRUE(PathService::Get(base::DIR_SYSTEM, &dll_path));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_SYSTEM, &dll_path));
dll_path = dll_path.Append(L"gdi32.dll");
} else {
- EXPECT_TRUE(PathService::Get(base::DIR_EXE, &dll_path));
+ EXPECT_TRUE(base::PathService::Get(base::DIR_EXE, &dll_path));
dll_path = dll_path.Append(hooking_dll::g_hook_dll_file);
}
EXPECT_TRUE(runner.AddFsRule(sandbox::TargetPolicy::FILES_ALLOW_READONLY,
diff --git a/services/catalog/entry_unittest.cc b/services/catalog/entry_unittest.cc
index 9c509fc3..ca16927 100644
--- a/services/catalog/entry_unittest.cc
+++ b/services/catalog/entry_unittest.cc
@@ -34,7 +34,7 @@
std::unique_ptr<base::Value> ReadManifest(const std::string& manifest) {
base::FilePath manifest_path;
- PathService::Get(base::DIR_SOURCE_ROOT, &manifest_path);
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &manifest_path);
manifest_path =
manifest_path.AppendASCII("services/catalog/test_data/" + manifest);
diff --git a/services/network/url_loader_unittest.cc b/services/network/url_loader_unittest.cc
index 99b3a40..bbbc964 100644
--- a/services/network/url_loader_unittest.cc
+++ b/services/network/url_loader_unittest.cc
@@ -459,7 +459,7 @@
// Returns the path of the requested file in the test data directory.
base::FilePath GetTestFilePath(const std::string& file_name) {
base::FilePath file_path;
- PathService::Get(base::DIR_SOURCE_ROOT, &file_path);
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &file_path);
file_path = file_path.Append(FILE_PATH_LITERAL("services"));
file_path = file_path.Append(FILE_PATH_LITERAL("test"));
file_path = file_path.Append(FILE_PATH_LITERAL("data"));
diff --git a/services/service_manager/runner/host/service_process_launcher_unittest.cc b/services/service_manager/runner/host/service_process_launcher_unittest.cc
index d1e764cd..bc6d54b 100644
--- a/services/service_manager/runner/host/service_process_launcher_unittest.cc
+++ b/services/service_manager/runner/host/service_process_launcher_unittest.cc
@@ -68,7 +68,7 @@
#endif // defined(OS_ANDROID)
TEST(ServiceProcessLauncherTest, MAYBE_StartJoin) {
base::FilePath service_manager_dir;
- PathService::Get(base::DIR_MODULE, &service_manager_dir);
+ base::PathService::Get(base::DIR_MODULE, &service_manager_dir);
base::test::ScopedTaskEnvironment scoped_task_environment;
base::FilePath test_service_path;
diff --git a/services/service_manager/sandbox/win/sandbox_win.cc b/services/service_manager/sandbox/win/sandbox_win.cc
index 50430a8e..6c72f29 100644
--- a/services/service_manager/sandbox/win/sandbox_win.cc
+++ b/services/service_manager/sandbox/win/sandbox_win.cc
@@ -152,7 +152,7 @@
sandbox::TargetPolicy::Semantics access,
sandbox::TargetPolicy* policy) {
base::FilePath directory;
- if (!PathService::Get(path, &directory))
+ if (!base::PathService::Get(path, &directory))
return false;
if (sub_dir)
@@ -342,7 +342,7 @@
// Add the policy for debug message only in debug
#ifndef NDEBUG
base::FilePath app_dir;
- if (!PathService::Get(base::DIR_MODULE, &app_dir))
+ if (!base::PathService::Get(base::DIR_MODULE, &app_dir))
return sandbox::SBOX_ERROR_GENERIC;
wchar_t long_path_buf[MAX_PATH];
@@ -363,7 +363,7 @@
// Add the policy for read-only PDB file access for stack traces.
#if !defined(OFFICIAL_BUILD)
base::FilePath exe;
- if (!PathService::Get(base::FILE_EXE, &exe))
+ if (!base::PathService::Get(base::FILE_EXE, &exe))
return sandbox::SBOX_ERROR_GENERIC;
base::FilePath pdb_path = exe.DirName().Append(L"*.pdb");
result = policy->AddRule(sandbox::TargetPolicy::SUBSYS_FILES,
diff --git a/services/shape_detection/face_detection_impl_mac_unittest.mm b/services/shape_detection/face_detection_impl_mac_unittest.mm
index 254c326..1c507b7 100644
--- a/services/shape_detection/face_detection_impl_mac_unittest.mm
+++ b/services/shape_detection/face_detection_impl_mac_unittest.mm
@@ -130,7 +130,7 @@
// Load image data from test directory.
base::FilePath image_path;
- ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &image_path));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &image_path));
image_path = image_path.AppendASCII(GetParam().image_path);
ASSERT_TRUE(base::PathExists(image_path));
std::string image_data;
diff --git a/services/shape_detection/face_detection_impl_win_unittest.cc b/services/shape_detection/face_detection_impl_win_unittest.cc
index 8b25fde5..b4babb2 100644
--- a/services/shape_detection/face_detection_impl_win_unittest.cc
+++ b/services/shape_detection/face_detection_impl_win_unittest.cc
@@ -72,7 +72,7 @@
// Load image data from test directory.
base::FilePath image_path;
- ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &image_path));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &image_path));
image_path = image_path.Append(FILE_PATH_LITERAL("services"))
.Append(FILE_PATH_LITERAL("test"))
.Append(FILE_PATH_LITERAL("data"))
diff --git a/services/shape_detection/text_detection_impl_win_unittest.cc b/services/shape_detection/text_detection_impl_win_unittest.cc
index 7e1cc544..427fe276 100644
--- a/services/shape_detection/text_detection_impl_win_unittest.cc
+++ b/services/shape_detection/text_detection_impl_win_unittest.cc
@@ -64,7 +64,7 @@
// Load image data from test directory.
base::FilePath image_path;
- ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &image_path));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_SOURCE_ROOT, &image_path));
image_path = image_path.Append(FILE_PATH_LITERAL("services"))
.Append(FILE_PATH_LITERAL("test"))
.Append(FILE_PATH_LITERAL("data"))
diff --git a/services/test/run_all_service_tests.cc b/services/test/run_all_service_tests.cc
index d9bfbce..9ba9046 100644
--- a/services/test/run_all_service_tests.cc
+++ b/services/test/run_all_service_tests.cc
@@ -29,7 +29,7 @@
ui::RegisterPathProvider();
base::FilePath ui_test_pak_path;
- ASSERT_TRUE(PathService::Get(ui::UI_TEST_PAK, &ui_test_pak_path));
+ ASSERT_TRUE(base::PathService::Get(ui::UI_TEST_PAK, &ui_test_pak_path));
ui::ResourceBundle::InitSharedInstanceWithPakPath(ui_test_pak_path);
#if defined(USE_OZONE)
diff --git a/sql/recovery_unittest.cc b/sql/recovery_unittest.cc
index 66df819..471cfd1 100644
--- a/sql/recovery_unittest.cc
+++ b/sql/recovery_unittest.cc
@@ -702,7 +702,7 @@
// case happened in <http://crbug.com/387868>.
TEST_F(SQLRecoveryTest, Bug387868) {
base::FilePath golden_path;
- ASSERT_TRUE(PathService::Get(sql::test::DIR_TEST_DATA, &golden_path));
+ ASSERT_TRUE(base::PathService::Get(sql::test::DIR_TEST_DATA, &golden_path));
golden_path = golden_path.AppendASCII("recovery_387868");
db().Close();
ASSERT_TRUE(base::CopyFile(golden_path, db_path()));
diff --git a/sql/test/paths.cc b/sql/test/paths.cc
index d7cc6e29..f8e5ad0 100644
--- a/sql/test/paths.cc
+++ b/sql/test/paths.cc
@@ -20,7 +20,7 @@
// will fail if executed from an installed executable (because the
// generated path won't exist).
case DIR_TEST_DATA:
- if (!PathService::Get(base::DIR_SOURCE_ROOT, &cur))
+ if (!base::PathService::Get(base::DIR_SOURCE_ROOT, &cur))
return false;
cur = cur.Append(FILE_PATH_LITERAL("sql"));
cur = cur.Append(FILE_PATH_LITERAL("test"));
@@ -41,7 +41,7 @@
// This cannot be done as a static initializer sadly since Visual Studio will
// eliminate this object file if there is no direct entry point into it.
void RegisterPathProvider() {
- PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
+ base::PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
}
} // namespace test
diff --git a/testing/libfuzzer/tests/fuzzer_launcher_test.cc b/testing/libfuzzer/tests/fuzzer_launcher_test.cc
index bd7cbc3..b617437 100644
--- a/testing/libfuzzer/tests/fuzzer_launcher_test.cc
+++ b/testing/libfuzzer/tests/fuzzer_launcher_test.cc
@@ -18,7 +18,7 @@
TEST(FuzzerConfigTest, DictOnly) {
// Test of automatically generated .options file for fuzzer with dict option.
base::FilePath exe_path;
- PathService::Get(base::FILE_EXE, &exe_path);
+ base::PathService::Get(base::FILE_EXE, &exe_path);
std::string launcher_path =
exe_path.DirName().Append("check_fuzzer_config.py").value();
@@ -39,7 +39,7 @@
TEST(FuzzerConfigTest, ConfigOnly) {
// Test of .options file for fuzzer with libfuzzer_options and without dict.
base::FilePath exe_path;
- PathService::Get(base::FILE_EXE, &exe_path);
+ base::PathService::Get(base::FILE_EXE, &exe_path);
std::string launcher_path =
exe_path.DirName().Append("check_fuzzer_config.py").value();
@@ -61,7 +61,7 @@
TEST(FuzzerConfigTest, ConfigAndDict) {
// Test of .options file for fuzzer with options file and dictionary.
base::FilePath exe_path;
- PathService::Get(base::FILE_EXE, &exe_path);
+ base::PathService::Get(base::FILE_EXE, &exe_path);
std::string launcher_path =
exe_path.DirName().Append("check_fuzzer_config.py").value();
@@ -85,7 +85,7 @@
TEST(FuzzerConfigTest, ConfigAndSeedCorpus) {
// Test of .options file for fuzzer with libfuzzer_options and seed corpus.
base::FilePath exe_path;
- PathService::Get(base::FILE_EXE, &exe_path);
+ base::PathService::Get(base::FILE_EXE, &exe_path);
std::string launcher_path =
exe_path.DirName().Append("check_fuzzer_config.py").value();
@@ -121,7 +121,7 @@
TEST(FuzzerConfigTest, ConfigAndSeedCorpuses) {
// Test of .options file for fuzzer with libfuzzer_options and seed corpuses.
base::FilePath exe_path;
- PathService::Get(base::FILE_EXE, &exe_path);
+ base::PathService::Get(base::FILE_EXE, &exe_path);
std::string launcher_path =
exe_path.DirName().Append("check_fuzzer_config.py").value();
@@ -157,7 +157,7 @@
TEST(FuzzerConfigTest, DictSubdir) {
// Test of auto-generated .options file for fuzzer with dict in sub-directory.
base::FilePath exe_path;
- PathService::Get(base::FILE_EXE, &exe_path);
+ base::PathService::Get(base::FILE_EXE, &exe_path);
std::string launcher_path =
exe_path.DirName().Append("check_fuzzer_config.py").value();
diff --git a/third_party/liblouis/nacl_wrapper/liblouis_wrapper_browsertest.cc b/third_party/liblouis/nacl_wrapper/liblouis_wrapper_browsertest.cc
index bc2fda2..af6e7b7 100644
--- a/third_party/liblouis/nacl_wrapper/liblouis_wrapper_browsertest.cc
+++ b/third_party/liblouis/nacl_wrapper/liblouis_wrapper_browsertest.cc
@@ -11,7 +11,7 @@
};
IN_PROC_BROWSER_TEST_F(LibLouisWrapperTest, LibLouisLoad) {
- ASSERT_TRUE(PathService::Get(base::DIR_EXE, &test_data_dir_));
+ ASSERT_TRUE(base::PathService::Get(base::DIR_EXE, &test_data_dir_));
test_data_dir_ = test_data_dir_.AppendASCII("chromevox_test_data");
LOG(ERROR) << "Test data dir: " << test_data_dir_.MaybeAsASCII();
ASSERT_TRUE(RunExtensionTest("braille")) << message_;
diff --git a/third_party/zlib/google/zip_reader_unittest.cc b/third_party/zlib/google/zip_reader_unittest.cc
index 0c74f37..dabe9f68 100644
--- a/third_party/zlib/google/zip_reader_unittest.cc
+++ b/third_party/zlib/google/zip_reader_unittest.cc
@@ -173,7 +173,7 @@
}
bool GetTestDataDirectory(base::FilePath* path) {
- bool success = PathService::Get(base::DIR_SOURCE_ROOT, path);
+ bool success = base::PathService::Get(base::DIR_SOURCE_ROOT, path);
EXPECT_TRUE(success);
if (!success)
return false;
diff --git a/third_party/zlib/google/zip_unittest.cc b/third_party/zlib/google/zip_unittest.cc
index 21e1f71..7ea3c36 100644
--- a/third_party/zlib/google/zip_unittest.cc
+++ b/third_party/zlib/google/zip_unittest.cc
@@ -165,7 +165,7 @@
}
bool GetTestDataDirectory(base::FilePath* path) {
- bool success = PathService::Get(base::DIR_SOURCE_ROOT, path);
+ bool success = base::PathService::Get(base::DIR_SOURCE_ROOT, path);
EXPECT_TRUE(success);
if (!success)
return false;
diff --git a/tools/battor_agent/battor_agent_bin.cc b/tools/battor_agent/battor_agent_bin.cc
index a9f11c5..4ccc1c9 100644
--- a/tools/battor_agent/battor_agent_bin.cc
+++ b/tools/battor_agent/battor_agent_bin.cc
@@ -364,7 +364,7 @@
if (trace_output_file_.empty()) {
// Save the detailed results in case they are needed.
base::FilePath default_path;
- PathService::Get(base::DIR_USER_DESKTOP, &default_path);
+ base::PathService::Get(base::DIR_USER_DESKTOP, &default_path);
default_path = default_path.Append(FILE_PATH_LITERAL("trace_data.txt"));
output_file = default_path.AsUTF8Unsafe().c_str();
std::cout << "Saving detailed results to " << output_file << std::endl;
diff --git a/tools/gn/command_format_unittest.cc b/tools/gn/command_format_unittest.cc
index c351df04..1780eb4 100644
--- a/tools/gn/command_format_unittest.cc
+++ b/tools/gn/command_format_unittest.cc
@@ -20,7 +20,7 @@
std::string out; \
std::string expected; \
base::FilePath src_dir; \
- PathService::Get(base::DIR_SOURCE_ROOT, &src_dir); \
+ base::PathService::Get(base::DIR_SOURCE_ROOT, &src_dir); \
base::SetCurrentDirectory(src_dir); \
EXPECT_TRUE(commands::FormatFileToString( \
&setup, SourceFile("//tools/gn/format_test_data/" #n ".gn"), false, \
diff --git a/tools/gn/ninja_build_writer.cc b/tools/gn/ninja_build_writer.cc
index 2f782f04..075592c 100644
--- a/tools/gn/ninja_build_writer.cc
+++ b/tools/gn/ninja_build_writer.cc
@@ -52,7 +52,7 @@
build_settings->build_dir().Resolve(build_settings->root_path());
base::FilePath exe_path;
- PathService::Get(base::FILE_EXE, &exe_path);
+ base::PathService::Get(base::FILE_EXE, &exe_path);
if (build_path.IsAbsolute())
exe_path = MakeAbsoluteFilePathRelativeIfPossible(build_path, exe_path);
diff --git a/tools/traffic_annotation/auditor/traffic_annotation_auditor_unittest.cc b/tools/traffic_annotation/auditor/traffic_annotation_auditor_unittest.cc
index 38b582dd..afda14fa 100644
--- a/tools/traffic_annotation/auditor/traffic_annotation_auditor_unittest.cc
+++ b/tools/traffic_annotation/auditor/traffic_annotation_auditor_unittest.cc
@@ -55,7 +55,7 @@
class TrafficAnnotationAuditorTest : public ::testing::Test {
public:
void SetUp() override {
- if (!PathService::Get(base::DIR_SOURCE_ROOT, &source_path_)) {
+ if (!base::PathService::Get(base::DIR_SOURCE_ROOT, &source_path_)) {
LOG(ERROR) << "Could not get current directory to find source path.";
return;
}
diff --git a/ui/compositor/layer_unittest.cc b/ui/compositor/layer_unittest.cc
index cc26fcaa..144e7c7e 100644
--- a/ui/compositor/layer_unittest.cc
+++ b/ui/compositor/layer_unittest.cc
@@ -130,7 +130,7 @@
class LayerWithRealCompositorTest : public testing::Test {
public:
LayerWithRealCompositorTest() {
- if (PathService::Get(gfx::DIR_TEST_DATA, &test_data_directory_)) {
+ if (base::PathService::Get(gfx::DIR_TEST_DATA, &test_data_directory_)) {
test_data_directory_ = test_data_directory_.AppendASCII("compositor");
} else {
LOG(ERROR) << "Could not open test data directory.";
diff --git a/webrunner/app/webrunner_main_delegate.cc b/webrunner/app/webrunner_main_delegate.cc
index 60005d3..2d1f931 100644
--- a/webrunner/app/webrunner_main_delegate.cc
+++ b/webrunner/app/webrunner_main_delegate.cc
@@ -21,7 +21,7 @@
base::FilePath log_filename;
std::string filename = command_line.GetSwitchValueASCII(switches::kLogFile);
if (filename.empty()) {
- PathService::Get(base::DIR_EXE, &log_filename);
+ base::PathService::Get(base::DIR_EXE, &log_filename);
log_filename = log_filename.AppendASCII("webrunner.log");
} else {
log_filename = base::FilePath::FromUTF8Unsafe(filename);