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// A handful of resource-like constants related to the Chrome application.
6
7#ifndef CHROME_COMMON_CHROME_CONSTANTS_H_
8#define CHROME_COMMON_CHROME_CONSTANTS_H_
9
10#include "base/files/file_path.h"
11
12namespace chrome {
13
14extern const char kChromeVersion[];
15
16extern const char kChromeVersionEnvVar[];
17
18extern const base::FilePath::CharType kBrowserProcessExecutableName[];
19extern const base::FilePath::CharType kHelperProcessExecutableName[];
20extern const base::FilePath::CharType kBrowserProcessExecutablePath[];
21extern const base::FilePath::CharType kHelperProcessExecutablePath[];
22extern const base::FilePath::CharType kBrowserProcessExecutableNameChromium[];
23extern const base::FilePath::CharType kHelperProcessExecutableNameChromium[];
24extern const base::FilePath::CharType kBrowserProcessExecutablePathChromium[];
25extern const base::FilePath::CharType kHelperProcessExecutablePathChromium[];
26#if defined(OS_MACOSX)
27extern const base::FilePath::CharType kFrameworkName[];
28
29// The helper .app bundle name and executable name may have one of these
30// suffixes to identify specific features, or it may have no suffix at all.
31// This is a NULL-terminated array of strings. If kHelperFlavorSuffixes
32// contains "EN", "MF", and NULL, it indicates that if the normal helper is
33// named Chromium Helper.app, helper executables could show up at any of
34// Chromium Helper.app/Contents/MacOS/Chromium Helper,
35// Chromium Helper EN.app/Contents/MacOS/Chromium Helper EN, and
36// Chromium Helper MF.app/Contents/MacOS/Chromium Helper MF.
37extern const base::FilePath::CharType* const kHelperFlavorSuffixes[];
38#endif  // OS_MACOSX
39#if defined(OS_WIN)
40extern const base::FilePath::CharType kMetroDriverDll[];
41extern const wchar_t kStatusTrayWindowClass[];
42#endif  // defined(OS_WIN)
43extern const wchar_t kCrashReportLog[];
44extern const wchar_t kTestingInterfaceDLL[];
45extern const char    kInitialProfile[];
46extern const char    kMultiProfileDirPrefix[];
47extern const base::FilePath::CharType kGuestProfileDir[];
48extern const wchar_t kBrowserResourcesDll[];
49
50// filenames
51#if defined(OS_ANDROID)
52extern const base::FilePath::CharType kAndroidCacheFilename[];
53#endif
54extern const base::FilePath::CharType kArchivedHistoryFilename[];
55extern const base::FilePath::CharType kBookmarksFileName[];
56extern const base::FilePath::CharType kCacheDirname[];
57extern const base::FilePath::CharType kCookieFilename[];
58extern const base::FilePath::CharType kCRLSetFilename[];
59extern const base::FilePath::CharType kCustomDictionaryFileName[];
60extern const base::FilePath::CharType kExtensionActivityLogFilename[];
61extern const base::FilePath::CharType kExtensionsCookieFilename[];
62extern const base::FilePath::CharType kFaviconsFilename[];
63extern const base::FilePath::CharType kFirstRunSentinel[];
64extern const base::FilePath::CharType kHistoryFilename[];
65extern const base::FilePath::CharType kJumpListIconDirname[];
66extern const base::FilePath::CharType kLocalStateFilename[];
67extern const base::FilePath::CharType kLocalStorePoolName[];
68extern const base::FilePath::CharType kLoginDataFileName[];
69extern const base::FilePath::CharType kManagedModePolicyFilename[];
70extern const base::FilePath::CharType kMediaCacheDirname[];
71extern const base::FilePath::CharType kNewTabThumbnailsFilename[];
72extern const base::FilePath::CharType kOBCertFilename[];
73extern const base::FilePath::CharType kPreferencesFilename[];
74extern const base::FilePath::CharType kReadmeFilename[];
75extern const base::FilePath::CharType kSafeBrowsingBaseFilename[];
76extern const base::FilePath::CharType kServiceStateFileName[];
77extern const base::FilePath::CharType kShortcutsDatabaseName[];
78extern const base::FilePath::CharType kSingletonCookieFilename[];
79extern const base::FilePath::CharType kSingletonLockFilename[];
80extern const base::FilePath::CharType kSingletonSocketFilename[];
81extern const base::FilePath::CharType kSyncCredentialsFilename[];
82extern const base::FilePath::CharType kThemePackFilename[];
83extern const base::FilePath::CharType kThumbnailsFilename[];
84extern const base::FilePath::CharType kTopSitesFilename[];
85extern const base::FilePath::CharType kWebAppDirname[];
86
87// File name of the Pepper Flash plugin on different platforms.
88extern const base::FilePath::CharType kPepperFlashPluginFilename[];
89
90// directory names
91extern const wchar_t kUserDataDirname[];
92
93extern const bool kRecordModeEnabled;
94
95// The language code used when the language of a page could not be detected.
96// (Matches what the CLD -Compact Language Detection- library reports.)
97extern const char* const kUnknownLanguageCode;
98
99// If a WebContents is impolite and displays a second JavaScript alert within
100// kJavaScriptMessageExpectedDelay of a previous JavaScript alert being
101// dismissed, display an option to suppress future alerts from this WebContents.
102extern const int kJavaScriptMessageExpectedDelay;
103
104// Are touch icons enabled? False by default.
105extern const bool kEnableTouchIcon;
106
107// Fraction of the total number of processes to be used for hosting
108// extensions. If we have more extensions than this percentage, we will start
109// combining extensions in existing processes. This allows web pages to have
110// enough render processes and not be starved when a lot of extensions are
111// installed.
112extern const float kMaxShareOfExtensionProcesses;
113
114#if defined(OS_LINUX)
115// The highest and lowest assigned OOM score adjustment
116// (oom_score_adj) used by the OomPriority Manager.
117extern const int kLowestRendererOomScore;
118extern const int kHighestRendererOomScore;
119#endif
120
121#if defined(OS_WIN)
122// This is used by the PreRead experiment.
123extern const char kPreReadEnvironmentVariable[];
124// Used by Metro Chrome to create the profile under a custom subdirectory.
125extern const wchar_t kMetroChromeUserDataSubDir[];
126// Used by Metro Chrome to initiate navigation and search requests.
127extern const wchar_t kMetroNavigationAndSearchMessage[];
128// Used by Metro Chrome to get information about the current tab.
129extern const wchar_t kMetroGetCurrentTabInfoMessage[];
130// Used by Metro Chrome to store activation state.
131extern const wchar_t kMetroRegistryPath[];
132extern const wchar_t kLaunchModeValue[];
133#endif
134
135#if defined(OS_CHROMEOS)
136// Chrome OS profile directories have custom prefix.
137// Profile path format: [user_data_dir]/u-[$hash]
138// Ex.: /home/chronos/u-0123456789
139extern const char kProfileDirPrefix[];
140#endif
141
142// Used to identify the application to the system AV function in Windows.
143extern const char kApplicationClientIDStringForAVScanning[];
144
145}  // namespace chrome
146
147#endif  // CHROME_COMMON_CHROME_CONSTANTS_H_
148