// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // Contains constants for known URLs and portions thereof. // Except for WebUI UI/Host/SubPage constants. Those go in // chrome/common/webui_url_constants.h. // // - The constants are divided into sections: Cross platform, platform-specific, // and feature-specific. // - When adding platform/feature specific constants, if there already exists an // appropriate #if block, use that. // - Keep the constants sorted by name within its section. // - Use the same order in this header and url_constants.cc. #ifndef CHROME_COMMON_URL_CONSTANTS_H_ #define CHROME_COMMON_URL_CONSTANTS_H_ #include #include "build/build_config.h" #include "build/chromeos_buildflags.h" #include "chrome/common/buildflags.h" #include "chrome/common/webui_url_constants.h" #include "content/public/common/url_constants.h" #include "ppapi/buildflags/buildflags.h" namespace chrome { // "Learn more" URL for accessibility image labels, linked from the permissions // dialog shown when a user enables the feature. extern const char kAccessibilityLabelsLearnMoreURL[]; // "Learn more" URL for when profile settings are automatically reset. extern const char kAutomaticSettingsResetLearnMoreURL[]; // "Learn more" URL for Advanced Protection download warnings. extern const char kAdvancedProtectionDownloadLearnMoreURL[]; // "Chrome Settings" URL for website notifications linked out from OSSettings. extern const char kAppNotificationsBrowserSettingsURL[]; // The URL for providing help when the Bluetooth adapter is off. extern const char kBluetoothAdapterOffHelpURL[]; // "Learn more" URL shown in the dialog to enable cloud services for Cast. extern const char kCastCloudServicesHelpURL[]; // The URL for the help center article to show when no Cast destination has been // found. extern const char kCastNoDestinationFoundURL[]; // The URL for the WebHID API help center article. extern const char kChooserHidOverviewUrl[]; // The URL for the Web Serial API help center article. extern const char kChooserSerialOverviewUrl[]; // The URL for the WebUsb help center article. extern const char kChooserUsbOverviewURL[]; // Link to the forum for Chrome Beta. extern const char kChromeBetaForumURL[]; // The URL for the help center article to fix Chrome update problems. extern const char kChromeFixUpdateProblems[]; // General help links for Chrome, opened using various actions. extern const char kChromeHelpViaKeyboardURL[]; extern const char kChromeHelpViaMenuURL[]; extern const char kChromeHelpViaWebUIURL[]; #if BUILDFLAG(IS_CHROMEOS_ASH) extern const char kChromeOsHelpViaWebUIURL[]; #endif // The chrome-native: scheme is used show pages rendered with platform specific // widgets instead of using HTML. extern const char kChromeNativeScheme[]; // Pages under chrome-search. extern const char kChromeSearchLocalNtpHost[]; // Host and URL for most visited iframes used on the Instant Extended NTP. extern const char kChromeSearchMostVisitedHost[]; extern const char kChromeSearchMostVisitedUrl[]; // URL for NTP custom background image selected from the user's machine and // filename for the version of the file in the Profile directory extern const char kChromeUIUntrustedNewTabPageBackgroundUrl[]; extern const char kChromeUIUntrustedNewTabPageBackgroundFilename[]; // Page under chrome-search. extern const char kChromeSearchRemoteNtpHost[]; // The chrome-search: scheme is served by the same backend as chrome:. However, // only specific URLDataSources are enabled to serve requests via the // chrome-search: scheme. See |InstantIOContext::ShouldServiceRequest| and its // callers for details. Note that WebUIBindings should never be granted to // chrome-search: pages. chrome-search: pages are displayable but not readable // by external search providers (that are rendered by Instant renderer // processes), and neither displayable nor readable by normal (non-Instant) web // pages. To summarize, a non-Instant process, when trying to access // 'chrome-search://something', will bump up against the following: // // 1. Renderer: The display-isolated check in WebKit will deny the request, // 2. Browser: Assuming they got by #1, the scheme checks in // URLDataSource::ShouldServiceRequest will deny the request, // 3. Browser: for specific sub-classes of URLDataSource, like ThemeSource // there are additional Instant-PID checks that make sure the request is // coming from a blessed Instant process, and deny the request. extern const char kChromeSearchScheme[]; // This is the base URL of content that can be embedded in chrome://new-tab-page // using an