OLD | NEW |
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 "mojo/shell/switches.h" | 5 #include "mojo/runner/switches.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 | 8 |
9 namespace switches { | 9 namespace switches { |
10 | 10 |
11 // Used just for debugging to make it easier to attach debuggers. The actual app | 11 // Used just for debugging to make it easier to attach debuggers. The actual app |
12 // path that is used is sent over IPC. | 12 // path that is used is sent over IPC. |
13 const char kApp[] = "app"; | 13 const char kApp[] = "app"; |
14 | 14 |
15 // Used internally by the main process to indicate that a new process should be | 15 // Used internally by the main process to indicate that a new process should be |
16 // a child process. Not for user use. | 16 // a child process. Not for user use. |
17 const char kChildProcess[] = "child-process"; | 17 const char kChildProcess[] = "child-process"; |
18 | 18 |
19 // Comma separated list like: | 19 // Comma separated list like: |
20 // text/html,mojo:html_viewer,application/bravo,https://abarth.com/bravo | 20 // text/html,mojo:html_viewer,application/bravo,https://abarth.com/bravo |
21 const char kContentHandlers[] = "content-handlers"; | 21 const char kContentHandlers[] = "content-handlers"; |
22 | 22 |
23 // Force dynamically loaded apps / services to be loaded irrespective of cache | 23 // Force dynamically loaded apps / services to be loaded irrespective of cache |
24 // instructions. | 24 // instructions. |
25 const char kDisableCache[] = "disable-cache"; | 25 const char kDisableCache[] = "disable-cache"; |
26 | 26 |
27 // If set apps downloaded are not deleted. | |
28 const char kDontDeleteOnDownload[] = "dont-delete-on-download"; | |
29 | |
30 // Load apps in separate processes. | 27 // Load apps in separate processes. |
31 // TODO(vtl): Work in progress; doesn't work. Flip this to "disable" (or maybe | 28 // TODO(vtl): Work in progress; doesn't work. Flip this to "disable" (or maybe |
32 // change it to "single-process") when it works. | 29 // change it to "single-process") when it works. |
33 const char kEnableMultiprocess[] = "enable-multiprocess"; | 30 const char kEnableMultiprocess[] = "enable-multiprocess"; |
34 | 31 |
35 // In multiprocess mode, force these apps to be loaded in the main process. | 32 // In multiprocess mode, force these apps to be loaded in the main process. |
36 // Comma-separate list of URLs. Example: | 33 // Comma-separate list of URLs. Example: |
37 // --force-in-process=mojo:native_viewport_service,mojo:network_service | 34 // --force-in-process=mojo:native_viewport_service,mojo:network_service |
38 const char kForceInProcess[] = "force-in-process"; | 35 const char kForceInProcess[] = "force-in-process"; |
39 | 36 |
40 // Print the usage message and exit. | 37 // Print the usage message and exit. |
41 const char kHelp[] = "help"; | 38 const char kHelp[] = "help"; |
42 | 39 |
43 // Specify origin to map to base url. See url_resolver.cc for details. | 40 // Specify origin to map to base url. See url_resolver.cc for details. |
44 // Can be used multiple times. | 41 // Can be used multiple times. |
45 const char kMapOrigin[] = "map-origin"; | 42 const char kMapOrigin[] = "map-origin"; |
46 | 43 |
47 // Map mojo: URLs to a shared library of similar name at this origin. See | 44 // Map mojo: URLs to a shared library of similar name at this origin. See |
48 // url_resolver.cc for details. | 45 // url_resolver.cc for details. |
49 const char kOrigin[] = "origin"; | 46 const char kOrigin[] = "origin"; |
50 | 47 |
51 // If set apps downloaded are saved in with a predictable filename, to help | |
52 // remote debugging: when gdb is used through gdbserver, it needs to be able to | |
53 // find locally any loaded library. For this, gdb use the filename of the | |
54 // library. When using this flag, the application are named with the sha256 of | |
55 // their content. | |
56 const char kPredictableAppFilenames[] = "predictable-app-filenames"; | |
57 | |
58 // Starts tracing when the shell starts up, saving a trace file on disk after 5 | 48 // Starts tracing when the shell starts up, saving a trace file on disk after 5 |
59 // seconds or when the shell exits. | 49 // seconds or when the shell exits. |
60 const char kTraceStartup[] = "trace-startup"; | 50 const char kTraceStartup[] = "trace-startup"; |
61 | 51 |
62 // Specifies a set of mappings to apply when resolving urls. The value is a set | 52 // Specifies a set of mappings to apply when resolving urls. The value is a set |
63 // of ',' separated mappings, where each mapping consists of a pair of urls | 53 // of ',' separated mappings, where each mapping consists of a pair of urls |
64 // giving the to/from url to map. For example, 'a=b,c=d' contains two mappings, | 54 // giving the to/from url to map. For example, 'a=b,c=d' contains two mappings, |
65 // the first maps 'a' to 'b' and the second 'c' to 'd'. | 55 // the first maps 'a' to 'b' and the second 'c' to 'd'. |
66 const char kURLMappings[] = "url-mappings"; | 56 const char kURLMappings[] = "url-mappings"; |
67 | 57 |
68 } // namespace switches | 58 } // namespace switches |
OLD | NEW |