| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/common/shell_switches.h" | 5 #include "content/shell/common/shell_switches.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/strings/string_split.h" | 8 #include "base/strings/string_split.h" |
| 9 | 9 |
| 10 namespace switches { | 10 namespace switches { |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 // whether or not reloading a webpage releases web-related objects correctly. | 45 // whether or not reloading a webpage releases web-related objects correctly. |
| 46 const char kEnableLeakDetection[] = "enable-leak-detection"; | 46 const char kEnableLeakDetection[] = "enable-leak-detection"; |
| 47 | 47 |
| 48 // Encode binary layout test results (images, audio) using base64. | 48 // Encode binary layout test results (images, audio) using base64. |
| 49 const char kEncodeBinary[] = "encode-binary"; | 49 const char kEncodeBinary[] = "encode-binary"; |
| 50 | 50 |
| 51 // Exposes the window.internals object to JavaScript for interactive development | 51 // Exposes the window.internals object to JavaScript for interactive development |
| 52 // and debugging of layout tests that rely on it. | 52 // and debugging of layout tests that rely on it. |
| 53 const char kExposeInternalsForTesting[] = "expose-internals-for-testing"; | 53 const char kExposeInternalsForTesting[] = "expose-internals-for-testing"; |
| 54 | 54 |
| 55 // Enable site isolation (--site-per-process style isolation) for a subset of |
| 56 // sites. The argument is a wildcard pattern which will be matched against the |
| 57 // site URL to determine which sites to isolate. This can be used to isolate |
| 58 // just one top-level domain, or just one scheme. Example usages: |
| 59 // --isolate-sites-for-testing=*.com |
| 60 // --isolate-sites-for-testing=https://* |
| 61 const char kIsolateSitesForTesting[] = "isolate-sites-for-testing"; |
| 62 |
| 55 // Registers additional font files on Windows (for fonts outside the usual | 63 // Registers additional font files on Windows (for fonts outside the usual |
| 56 // %WINDIR%\Fonts location). Multiple files can be used by separating them | 64 // %WINDIR%\Fonts location). Multiple files can be used by separating them |
| 57 // with a semicolon (;). | 65 // with a semicolon (;). |
| 58 const char kRegisterFontFiles[] = "register-font-files"; | 66 const char kRegisterFontFiles[] = "register-font-files"; |
| 59 | 67 |
| 60 // Request the render trees of pages to be dumped as text once they have | 68 // Request the render trees of pages to be dumped as text once they have |
| 61 // finished loading. | 69 // finished loading. |
| 62 const char kRunLayoutTest[] = "run-layout-test"; | 70 const char kRunLayoutTest[] = "run-layout-test"; |
| 63 | 71 |
| 64 // This makes us disable some web-platform runtime features so that we test | 72 // This makes us disable some web-platform runtime features so that we test |
| (...skipping 11 matching lines...) Expand all Loading... |
| 76 *base::CommandLine::ForCurrentProcess(); | 84 *base::CommandLine::ForCurrentProcess(); |
| 77 if (command_line.HasSwitch(switches::kRegisterFontFiles)) { | 85 if (command_line.HasSwitch(switches::kRegisterFontFiles)) { |
| 78 files = base::SplitString( | 86 files = base::SplitString( |
| 79 command_line.GetSwitchValueASCII(switches::kRegisterFontFiles), | 87 command_line.GetSwitchValueASCII(switches::kRegisterFontFiles), |
| 80 ";", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); | 88 ";", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); |
| 81 } | 89 } |
| 82 return files; | 90 return files; |
| 83 } | 91 } |
| 84 | 92 |
| 85 } // namespace switches | 93 } // namespace switches |
| OLD | NEW |