Index: content/browser/browser_url_handler_impl.cc |
=================================================================== |
--- content/browser/browser_url_handler_impl.cc (revision 164795) |
+++ content/browser/browser_url_handler_impl.cc (working copy) |
@@ -10,11 +10,11 @@ |
#include "content/public/common/url_constants.h" |
#include "googleurl/src/gurl.h" |
-using content::BrowserURLHandler; |
+namespace content { |
// Handles rewriting view-source URLs for what we'll actually load. |
static bool HandleViewSource(GURL* url, |
- content::BrowserContext* browser_context) { |
+ BrowserContext* browser_context) { |
if (url->SchemeIs(chrome::kViewSourceScheme)) { |
// Load the inner URL instead. |
*url = GURL(url->path()); |
@@ -46,8 +46,7 @@ |
} |
// Turns a non view-source URL into the corresponding view-source URL. |
-static bool ReverseViewSource(GURL* url, |
- content::BrowserContext* browser_context) { |
+static bool ReverseViewSource(GURL* url, BrowserContext* browser_context) { |
// No action necessary if the URL is already view-source: |
if (url->SchemeIs(chrome::kViewSourceScheme)) |
return false; |
@@ -61,8 +60,7 @@ |
return true; |
} |
-static bool HandleDebugUrl(GURL* url, |
- content::BrowserContext* browser_context) { |
+static bool HandleDebugUrl(GURL* url, BrowserContext* browser_context) { |
// Circumvent processing URLs that the renderer process will handle. |
return *url == GURL(chrome::kChromeUICrashURL) || |
*url == GURL(chrome::kChromeUIHangURL) || |
@@ -89,7 +87,7 @@ |
BrowserURLHandlerImpl::BrowserURLHandlerImpl() { |
AddHandlerPair(&HandleDebugUrl, BrowserURLHandlerImpl::null_handler()); |
- content::GetContentClient()->browser()->BrowserURLHandlerCreated(this); |
+ GetContentClient()->browser()->BrowserURLHandlerCreated(this); |
// view-source: |
AddHandlerPair(&HandleViewSource, &ReverseViewSource); |
@@ -105,7 +103,7 @@ |
void BrowserURLHandlerImpl::RewriteURLIfNecessary( |
GURL* url, |
- content::BrowserContext* browser_context, |
+ BrowserContext* browser_context, |
bool* reverse_on_redirect) { |
for (size_t i = 0; i < url_handlers_.size(); ++i) { |
URLHandler handler = *url_handlers_[i].first; |
@@ -117,7 +115,7 @@ |
} |
bool BrowserURLHandlerImpl::ReverseURLRewrite( |
- GURL* url, const GURL& original, content::BrowserContext* browser_context) { |
+ GURL* url, const GURL& original, BrowserContext* browser_context) { |
for (size_t i = 0; i < url_handlers_.size(); ++i) { |
URLHandler reverse_rewriter = *url_handlers_[i].second; |
if (reverse_rewriter) { |
@@ -133,3 +131,5 @@ |
} |
return false; |
} |
+ |
+} // namespace content |