summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
Diffstat (limited to 'chrome')
-rw-r--r--chrome/app/chrome_dll_main.cc2
-rw-r--r--chrome/common/chrome_paths.cc19
-rw-r--r--chrome/common/chrome_paths.h2
3 files changed, 21 insertions, 2 deletions
diff --git a/chrome/app/chrome_dll_main.cc b/chrome/app/chrome_dll_main.cc
index 97e059d..be727ef 100644
--- a/chrome/app/chrome_dll_main.cc
+++ b/chrome/app/chrome_dll_main.cc
@@ -29,7 +29,6 @@
#include <string.h>
#endif
-#include "app/app_paths.h"
#include "app/resource_bundle.h"
#include "base/at_exit.h"
#include "base/command_line.h"
@@ -332,7 +331,6 @@ int ChromeMain(int argc, const char** argv) {
SetupCRT(parsed_command_line);
// Initialize the Chrome path provider.
- app::RegisterPathProvider();
chrome::RegisterPathProvider();
// Initialize the Stats Counters table. With this initialized,
diff --git a/chrome/common/chrome_paths.cc b/chrome/common/chrome_paths.cc
index 1c307ed..c1b4ce6 100644
--- a/chrome/common/chrome_paths.cc
+++ b/chrome/common/chrome_paths.cc
@@ -92,6 +92,25 @@ bool PathProvider(int key, FilePath* result) {
cur = cur.Append(FILE_PATH_LITERAL("resources"));
cur = cur.Append(FILE_PATH_LITERAL("inspector"));
break;
+ case chrome::DIR_THEMES:
+ if (!PathService::Get(chrome::DIR_APP, &cur))
+ return false;
+ cur = cur.Append(FILE_PATH_LITERAL("themes"));
+ create_dir = true;
+ break;
+ case chrome::DIR_LOCALES:
+ if (!PathService::Get(chrome::DIR_APP, &cur))
+ return false;
+#if defined(OS_MACOSX)
+ // On Mac, locale files are in Contents/Resources, a sibling of the
+ // App dir.
+ cur = cur.DirName();
+ cur = cur.Append(FILE_PATH_LITERAL("Resources"));
+#else
+ cur = cur.Append(FILE_PATH_LITERAL("locales"));
+#endif
+ create_dir = true;
+ break;
case chrome::DIR_APP_DICTIONARIES:
#if defined(OS_LINUX)
// We can't write into the EXE dir on Linux, so keep dictionaries
diff --git a/chrome/common/chrome_paths.h b/chrome/common/chrome_paths.h
index 9f5b3cf..fe01807 100644
--- a/chrome/common/chrome_paths.h
+++ b/chrome/common/chrome_paths.h
@@ -20,6 +20,8 @@ enum {
DIR_USER_DESKTOP, // directory that correspond to the desktop
DIR_RESOURCES, // directory where application resources are stored
DIR_INSPECTOR, // directory where web inspector is located
+ DIR_THEMES, // directory where theme dll files are stored
+ DIR_LOCALES, // directory where locale resources are stored
DIR_APP_DICTIONARIES, // directory where the global dictionaries are
DIR_USER_DOCUMENTS, // directory for a user's "My Documents"
DIR_DEFAULT_DOWNLOADS, // directory for a user's "My Documents/Downloads"