Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(802)

Unified Diff: extensions/common/url_pattern.cc

Issue 120593003: Move kFileScheme constant into content namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « extensions/common/permissions/permissions_data.cc ('k') | extensions/common/url_pattern_set.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/common/url_pattern.cc
diff --git a/extensions/common/url_pattern.cc b/extensions/common/url_pattern.cc
index 2591cb7a101143933cd42036a5839cd45057dd3a..ab33bd876b89daf9c862838b4640c86d878723d2 100644
--- a/extensions/common/url_pattern.cc
+++ b/extensions/common/url_pattern.cc
@@ -22,7 +22,7 @@ namespace {
const char* kValidSchemes[] = {
content::kHttpScheme,
content::kHttpsScheme,
- chrome::kFileScheme,
+ content::kFileScheme,
content::kFtpScheme,
chrome::kChromeUIScheme,
extensions::kExtensionScheme,
@@ -192,7 +192,7 @@ URLPattern::ParseResult URLPattern::Parse(const std::string& pattern) {
if (!standard_scheme) {
path_start_pos = host_start_pos;
- } else if (scheme_ == chrome::kFileScheme) {
+ } else if (scheme_ == content::kFileScheme) {
size_t host_end_pos = pattern.find(kPathSeparator, host_start_pos);
if (host_end_pos == std::string::npos) {
// Allow hostname omission.
@@ -426,7 +426,7 @@ const std::string& URLPattern::GetAsString() const {
std::string spec = scheme_ +
(standard_scheme ? content::kStandardSchemeSeparator : ":");
- if (scheme_ != chrome::kFileScheme && standard_scheme) {
+ if (scheme_ != content::kFileScheme && standard_scheme) {
if (match_subdomains_) {
spec += "*";
if (!host_.empty())
@@ -493,7 +493,7 @@ bool URLPattern::MatchesAllSchemes(
bool URLPattern::MatchesSecurityOriginHelper(const GURL& test) const {
// Ignore hostname if scheme is file://.
- if (scheme_ != chrome::kFileScheme && !MatchesHost(test))
+ if (scheme_ != content::kFileScheme && !MatchesHost(test))
return false;
if (!MatchesPortPattern(base::IntToString(test.EffectiveIntPort())))
« no previous file with comments | « extensions/common/permissions/permissions_data.cc ('k') | extensions/common/url_pattern_set.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698