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

Unified Diff: chrome/common/chrome_content_client.cc

Issue 1301563003: Revert of Allow url::SchemeHostPort to hold non-file scheme without port (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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/chrome_content_client.h ('k') | chrome/common/chrome_content_client_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/chrome_content_client.cc
diff --git a/chrome/common/chrome_content_client.cc b/chrome/common/chrome_content_client.cc
index 427b4d6bcca63a7fbb5b08cbf638384ede41c4d0..f3b14b3a14ed00b2f2805719173cac6535d0492f 100644
--- a/chrome/common/chrome_content_client.cc
+++ b/chrome/common/chrome_content_client.cc
@@ -508,33 +508,21 @@
#endif // defined(ENABLE_PLUGINS)
}
+void ChromeContentClient::AddAdditionalSchemes(
+ std::vector<std::string>* standard_schemes,
+ std::vector<std::string>* savable_schemes) {
+ standard_schemes->push_back(extensions::kExtensionScheme);
+ savable_schemes->push_back(extensions::kExtensionScheme);
+ standard_schemes->push_back(chrome::kChromeNativeScheme);
+ standard_schemes->push_back(extensions::kExtensionResourceScheme);
+ savable_schemes->push_back(extensions::kExtensionResourceScheme);
+ standard_schemes->push_back(chrome::kChromeSearchScheme);
+ savable_schemes->push_back(chrome::kChromeSearchScheme);
+ standard_schemes->push_back(dom_distiller::kDomDistillerScheme);
+ savable_schemes->push_back(dom_distiller::kDomDistillerScheme);
#if defined(OS_CHROMEOS)
-static const int kNumChromeStandardURLSchemes = 6;
-#else
-static const int kNumChromeStandardURLSchemes = 5;
-#endif
-static const url::SchemeWithType kChromeStandardURLSchemes[
- kNumChromeStandardURLSchemes] = {
- {extensions::kExtensionScheme, url::SCHEME_WITHOUT_PORT},
- {chrome::kChromeNativeScheme, url::SCHEME_WITHOUT_PORT},
- {extensions::kExtensionResourceScheme, url::SCHEME_WITHOUT_PORT},
- {chrome::kChromeSearchScheme, url::SCHEME_WITHOUT_PORT},
- {dom_distiller::kDomDistillerScheme, url::SCHEME_WITHOUT_PORT},
-#if defined(OS_CHROMEOS)
- {chrome::kCrosScheme, url::SCHEME_WITHOUT_PORT},
-#endif
-};
-
-void ChromeContentClient::AddAdditionalSchemes(
- std::vector<url::SchemeWithType>* standard_schemes,
- std::vector<std::string>* savable_schemes) {
- for (int i = 0; i < kNumChromeStandardURLSchemes; i++)
- standard_schemes->push_back(kChromeStandardURLSchemes[i]);
-
- savable_schemes->push_back(extensions::kExtensionScheme);
- savable_schemes->push_back(extensions::kExtensionResourceScheme);
- savable_schemes->push_back(chrome::kChromeSearchScheme);
- savable_schemes->push_back(dom_distiller::kDomDistillerScheme);
+ standard_schemes->push_back(chrome::kCrosScheme);
+#endif
}
std::string ChromeContentClient::GetProduct() const {
« no previous file with comments | « chrome/common/chrome_content_client.h ('k') | chrome/common/chrome_content_client_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698