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

Side by Side Diff: content/shell/browser/shell_content_browser_client.cc

Issue 120593003: Move kFileScheme constant into content namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/shell/browser/shell_content_browser_client.h" 5 #include "content/shell/browser/shell_content_browser_client.h"
6 6
7 #include "base/base_switches.h" 7 #include "base/base_switches.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 return false; 177 return false;
178 DCHECK_EQ(url.scheme(), StringToLowerASCII(url.scheme())); 178 DCHECK_EQ(url.scheme(), StringToLowerASCII(url.scheme()));
179 // Keep in sync with ProtocolHandlers added by 179 // Keep in sync with ProtocolHandlers added by
180 // ShellURLRequestContextGetter::GetURLRequestContext(). 180 // ShellURLRequestContextGetter::GetURLRequestContext().
181 static const char* const kProtocolList[] = { 181 static const char* const kProtocolList[] = {
182 chrome::kBlobScheme, 182 chrome::kBlobScheme,
183 kFileSystemScheme, 183 kFileSystemScheme,
184 chrome::kChromeUIScheme, 184 chrome::kChromeUIScheme,
185 chrome::kChromeDevToolsScheme, 185 chrome::kChromeDevToolsScheme,
186 chrome::kDataScheme, 186 chrome::kDataScheme,
187 chrome::kFileScheme, 187 kFileScheme,
188 }; 188 };
189 for (size_t i = 0; i < arraysize(kProtocolList); ++i) { 189 for (size_t i = 0; i < arraysize(kProtocolList); ++i) {
190 if (url.scheme() == kProtocolList[i]) 190 if (url.scheme() == kProtocolList[i])
191 return true; 191 return true;
192 } 192 }
193 return false; 193 return false;
194 } 194 }
195 195
196 void ShellContentBrowserClient::AppendExtraCommandLineSwitches( 196 void ShellContentBrowserClient::AppendExtraCommandLineSwitches(
197 CommandLine* command_line, int child_process_id) { 197 CommandLine* command_line, int child_process_id) {
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
330 ShellBrowserContext* 330 ShellBrowserContext*
331 ShellContentBrowserClient::ShellBrowserContextForBrowserContext( 331 ShellContentBrowserClient::ShellBrowserContextForBrowserContext(
332 BrowserContext* content_browser_context) { 332 BrowserContext* content_browser_context) {
333 if (content_browser_context == browser_context()) 333 if (content_browser_context == browser_context())
334 return browser_context(); 334 return browser_context();
335 DCHECK_EQ(content_browser_context, off_the_record_browser_context()); 335 DCHECK_EQ(content_browser_context, off_the_record_browser_context());
336 return off_the_record_browser_context(); 336 return off_the_record_browser_context();
337 } 337 }
338 338
339 } // namespace content 339 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_view_impl.cc ('k') | content/shell/browser/shell_url_request_context_getter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698