chrome_paths.h revision 5821806d5e7f356e8fa4b058a389a808ea183019
1// Copyright (c) 2012 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef CHROME_COMMON_CHROME_PATHS_H__
6#define CHROME_COMMON_CHROME_PATHS_H__
7
8#include "build/build_config.h"
9
10// This file declares path keys for the chrome module.  These can be used with
11// the PathService to access various special directories and files.
12
13namespace chrome {
14
15enum {
16  PATH_START = 1000,
17
18  DIR_APP = PATH_START,         // Directory where dlls and data reside.
19  DIR_LOGS,                     // Directory where logs should be written.
20  DIR_USER_DATA,                // Directory where user data can be written.
21#if defined(OS_WIN)
22  DIR_ALT_USER_DATA,            // Directory of the desktop or metro user data
23                                // (the one that isn't in use).
24#endif
25  DIR_CRASH_DUMPS,              // Directory where crash dumps are written.
26  DIR_RESOURCES,                // Directory containing separate file resources
27                                // used by Chrome at runtime.
28  DIR_INSPECTOR,                // Directory where web inspector is located.
29  DIR_APP_DICTIONARIES,         // Directory where the global dictionaries are.
30  DIR_USER_DOCUMENTS,           // Directory for a user's "My Documents".
31  DIR_USER_MUSIC,               // Directory for a user's music.
32  DIR_USER_PICTURES,            // Directory for a user's pictures.
33  DIR_USER_VIDEOS,              // Directory for a user's videos.
34  DIR_DEFAULT_DOWNLOADS_SAFE,   // Directory for a user's
35                                // "My Documents/Downloads", (Windows) or
36                                // "Downloads". (Linux)
37  DIR_DEFAULT_DOWNLOADS,        // Directory for a user's downloads.
38  DIR_INTERNAL_PLUGINS,         // Directory where internal plugins reside.
39#if defined(OS_POSIX) && !defined(OS_MACOSX)
40  DIR_POLICY_FILES,             // Directory for system-wide read-only
41                                // policy files that allow sys-admins
42                                // to set policies for chrome. This directory
43                                // contains subdirectories.
44#endif
45#if defined(OS_MACOSX)
46  DIR_MANAGED_PREFS,            // Directory that stores the managed prefs plist
47                                // files for the current user.
48#endif
49#if defined(OS_CHROMEOS) || defined(OS_MACOSX)
50  DIR_USER_EXTERNAL_EXTENSIONS,  // Directory for per-user external extensions
51                                 // on Chrome Mac.  On Chrome OS, this path is
52                                 // used for OEM customization.
53                                 // Getting this path does not create it.
54#endif
55
56#if defined(OS_LINUX)
57  DIR_STANDALONE_EXTERNAL_EXTENSIONS,  // Directory for 'per-extension'
58                                       // definition manifest files that
59                                       // describe extensions which are to be
60                                       // installed when chrome is run.
61#endif
62  DIR_EXTERNAL_EXTENSIONS,      // Directory where installer places .crx files.
63
64  DIR_DEFAULT_APPS,             // Directory where installer places .crx files
65                                // to be installed when chrome is first run.
66  DIR_PEPPER_FLASH_PLUGIN,      // Directory to the bundled Pepper Flash plugin,
67                                // containing the plugin and the manifest.
68  DIR_COMPONENT_UPDATED_PEPPER_FLASH_PLUGIN,  // Base directory of the Pepper
69                                              // Flash plugins downloaded by the
70                                              // component updater.
71  FILE_RESOURCE_MODULE,         // Full path and filename of the module that
72                                // contains embedded resources (version,
73                                // strings, images, etc.).
74  FILE_LOCAL_STATE,             // Path and filename to the file in which
75                                // machine/installation-specific state is saved.
76  FILE_RECORDED_SCRIPT,         // Full path to the script.log file that
77                                // contains recorded browser events for
78                                // playback.
79  FILE_FLASH_PLUGIN,            // Full path to the internal Flash plugin file.
80                                // Querying this path will succeed no matter the
81                                // file exists or not.
82  FILE_FLASH_PLUGIN_EXISTING,   // Full path to the internal Flash plugin file.
83                                // Querying this path will fail if the file
84                                // doesn't exist.
85  FILE_PEPPER_FLASH_PLUGIN,     // Full path to the bundled Pepper Flash plugin
86                                // file.
87  FILE_PDF_PLUGIN,              // Full path to the internal PDF plugin file.
88
89#if defined(OS_POSIX) && !defined(OS_MACOSX)
90  FILE_NACL_HELPER,             // Full path to Linux nacl_helper executable.
91  FILE_NACL_HELPER_BOOTSTRAP,   // ... and nacl_helper_bootstrap executable.
92#endif
93  FILE_NACL_PLUGIN,             // Full path to the internal NaCl plugin file.
94  DIR_PNACL_BASE,               // Full path to the base dir for PNaCl.
95  DIR_PNACL_COMPONENT,          // Full path to the latest PNaCl version
96                                // (subdir of DIR_PNACL_BASE).
97  FILE_O3D_PLUGIN,              // Full path to the O3D Pepper plugin file.
98  FILE_GTALK_PLUGIN,            // Full path to the GTalk Pepper plugin file.
99  FILE_WIDEVINE_CDM_PLUGIN,     // Full path to the Widevine CDM Pepper plugin
100                                // file.
101  FILE_RESOURCES_PACK,          // Full path to the .pak file containing
102                                // binary data (e.g., html files and images
103                                // used by interal pages).
104  DIR_RESOURCES_EXTENSION,      // Full path to extension resources.
105#if defined(OS_CHROMEOS)
106  DIR_CHROMEOS_WALLPAPERS,      // Directory where downloaded chromeos
107                                // wallpapers reside.
108  FILE_DEFAULT_APP_ORDER,       // Full path to the json file that defines the
109                                // default app order.
110#endif
111
112  // Valid only in development environment; TODO(darin): move these
113  DIR_GEN_TEST_DATA,            // Directory where generated test data resides.
114  DIR_TEST_DATA,                // Directory where unit test data resides.
115  DIR_TEST_TOOLS,               // Directory where unit test tools reside.
116
117  PATH_END
118};
119
120// Call once to register the provider for the path keys defined above.
121void RegisterPathProvider();
122
123}  // namespace chrome
124
125#endif  // CHROME_COMMON_CHROME_PATHS_H__
126