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

Unified Diff: chrome/common/extensions/url_pattern.h

Issue 10224011: Add transparent support for filesystem URLs in URLPatterns. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Updated MatchesSecurityOrigin and added a comment, as discussed in IM. Created 8 years, 8 months 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 | « chrome/common/extensions/extension.cc ('k') | chrome/common/extensions/url_pattern.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/url_pattern.h
diff --git a/chrome/common/extensions/url_pattern.h b/chrome/common/extensions/url_pattern.h
index 3cde957c2c11d9ed57e1ca641bed4b57ecefd589..ace2dc863097031a3e8c58f7f1f94f74c79209ed 100644
--- a/chrome/common/extensions/url_pattern.h
+++ b/chrome/common/extensions/url_pattern.h
@@ -119,15 +119,6 @@ class URLPattern {
bool match_all_urls() const { return match_all_urls_; }
void SetMatchAllURLs(bool val);
- // Returns true if this pattern matches inner URLs of filesystem: URLs only.
- // Returns false if this pattern matches only non-filesystem URLs.
- bool partial_filesystem_support_hack() const {
- return partial_filesystem_support_hack_;
- }
- void set_partial_filesystem_support_hack(bool val) {
- partial_filesystem_support_hack_ = val;
- }
-
// Sets the scheme for pattern matches. This can be a single '*' if the
// pattern matches all valid schemes (as defined by the valid_schemes_
// property). Returns false on failure (if the scheme is not valid).
@@ -147,6 +138,9 @@ class URLPattern {
bool MatchesSecurityOrigin(const GURL& test) const;
// Returns true if |test| matches our scheme.
+ // Note that if test is "filesystem", this may fail whereas MatchesURL
+ // may succeed. MatchesURL is smart enough to look at the inner_url instead
+ // of the outer "filesystem:" part.
bool MatchesScheme(const std::string& test) const;
// Returns true if |test| matches our host.
@@ -213,11 +207,6 @@ class URLPattern {
// True if this is a special-case "<all_urls>" pattern.
bool match_all_urls_;
- // True if we're trying to match against the inner URL of a filesystem URL;
- // this is a temporary hack so as not to break ChromeOS as we work on full
- // support.
- bool partial_filesystem_support_hack_;
-
// The scheme for the pattern.
std::string scheme_;
« no previous file with comments | « chrome/common/extensions/extension.cc ('k') | chrome/common/extensions/url_pattern.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698