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

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

Issue 1763113002: Move layout-test-specific switches from shell_switches to layout_test_switches.h (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remove-line-box-and-debug-from-flags-struct
Patch Set: Fix accidental condition reversal in Shell::ToggleFullscreenModeForTab. Created 4 years, 9 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
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 <stddef.h> 7 #include <stddef.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/base_switches.h" 10 #include "base/base_switches.h"
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 void ShellContentBrowserClient::RegisterOutOfProcessMojoApplications( 227 void ShellContentBrowserClient::RegisterOutOfProcessMojoApplications(
228 OutOfProcessMojoApplicationMap* apps) { 228 OutOfProcessMojoApplicationMap* apps) {
229 apps->insert(std::make_pair(kTestMojoAppUrl, 229 apps->insert(std::make_pair(kTestMojoAppUrl,
230 base::UTF8ToUTF16("Test Mojo App"))); 230 base::UTF8ToUTF16("Test Mojo App")));
231 } 231 }
232 232
233 void ShellContentBrowserClient::AppendExtraCommandLineSwitches( 233 void ShellContentBrowserClient::AppendExtraCommandLineSwitches(
234 base::CommandLine* command_line, 234 base::CommandLine* command_line,
235 int child_process_id) { 235 int child_process_id) {
236 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 236 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
237 switches::kEnableFontAntialiasing)) {
238 command_line->AppendSwitch(switches::kEnableFontAntialiasing);
239 }
240 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
241 switches::kAlwaysUseComplexText)) {
242 command_line->AppendSwitch(switches::kAlwaysUseComplexText);
243 }
244 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
245 switches::kExposeInternalsForTesting)) {
246 command_line->AppendSwitch(switches::kExposeInternalsForTesting);
247 }
248 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
249 switches::kStableReleaseMode)) {
250 command_line->AppendSwitch(switches::kStableReleaseMode);
251 }
252 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
253 switches::kEnableCrashReporter)) { 237 switches::kEnableCrashReporter)) {
254 command_line->AppendSwitch(switches::kEnableCrashReporter); 238 command_line->AppendSwitch(switches::kEnableCrashReporter);
255 } 239 }
256 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 240 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
257 switches::kCrashDumpsDir)) { 241 switches::kCrashDumpsDir)) {
258 command_line->AppendSwitchPath( 242 command_line->AppendSwitchPath(
259 switches::kCrashDumpsDir, 243 switches::kCrashDumpsDir,
260 base::CommandLine::ForCurrentProcess()->GetSwitchValuePath( 244 base::CommandLine::ForCurrentProcess()->GetSwitchValuePath(
261 switches::kCrashDumpsDir)); 245 switches::kCrashDumpsDir));
262 } 246 }
263 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 247 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
264 switches::kEnableLeakDetection)) {
265 command_line->AppendSwitchASCII(
266 switches::kEnableLeakDetection,
267 base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
268 switches::kEnableLeakDetection));
269 }
270 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
271 switches::kIsolateSitesForTesting)) { 248 switches::kIsolateSitesForTesting)) {
272 command_line->AppendSwitchASCII( 249 command_line->AppendSwitchASCII(
273 switches::kIsolateSitesForTesting, 250 switches::kIsolateSitesForTesting,
274 base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII( 251 base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
275 switches::kIsolateSitesForTesting)); 252 switches::kIsolateSitesForTesting));
276 } 253 }
277 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 254 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
278 switches::kRegisterFontFiles)) { 255 switches::kRegisterFontFiles)) {
279 command_line->AppendSwitchASCII( 256 command_line->AppendSwitchASCII(
280 switches::kRegisterFontFiles, 257 switches::kRegisterFontFiles,
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
417 ShellBrowserContext* 394 ShellBrowserContext*
418 ShellContentBrowserClient::ShellBrowserContextForBrowserContext( 395 ShellContentBrowserClient::ShellBrowserContextForBrowserContext(
419 BrowserContext* content_browser_context) { 396 BrowserContext* content_browser_context) {
420 if (content_browser_context == browser_context()) 397 if (content_browser_context == browser_context())
421 return browser_context(); 398 return browser_context();
422 DCHECK_EQ(content_browser_context, off_the_record_browser_context()); 399 DCHECK_EQ(content_browser_context, off_the_record_browser_context());
423 return off_the_record_browser_context(); 400 return off_the_record_browser_context();
424 } 401 }
425 402
426 } // namespace content 403 } // namespace content
OLDNEW
« no previous file with comments | « content/shell/browser/shell.cc ('k') | content/shell/browser/shell_web_contents_view_delegate_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698