OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. |
3 * Copyright (C) 2007 Matt Lilek (pewtermoose@gmail.com). | 3 * Copyright (C) 2007 Matt Lilek (pewtermoose@gmail.com). |
4 * Copyright (C) 2009 Joseph Pecoraro | 4 * Copyright (C) 2009 Joseph Pecoraro |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * | 9 * |
10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 Runtime.experiments.register("layersPanel", "Layers panel"); | 156 Runtime.experiments.register("layersPanel", "Layers panel"); |
157 Runtime.experiments.register("promiseTracker", "Enable Promise inspectio
n", true); | 157 Runtime.experiments.register("promiseTracker", "Enable Promise inspectio
n", true); |
158 Runtime.experiments.register("suggestUsingWorkspace", "Suggest using wor
kspace", true); | 158 Runtime.experiments.register("suggestUsingWorkspace", "Suggest using wor
kspace", true); |
159 Runtime.experiments.register("timelineOnTraceEvents", "Timeline on trace
events"); | 159 Runtime.experiments.register("timelineOnTraceEvents", "Timeline on trace
events"); |
160 Runtime.experiments.register("timelinePowerProfiler", "Timeline power pr
ofiler"); | 160 Runtime.experiments.register("timelinePowerProfiler", "Timeline power pr
ofiler"); |
161 Runtime.experiments.register("timelineJSCPUProfile", "Timeline with JS s
ampling"); | 161 Runtime.experiments.register("timelineJSCPUProfile", "Timeline with JS s
ampling"); |
162 Runtime.experiments.cleanUpStaleExperiments(); | 162 Runtime.experiments.cleanUpStaleExperiments(); |
163 | 163 |
164 if (InspectorFrontendHost.isUnderTest()) { | 164 if (InspectorFrontendHost.isUnderTest()) { |
165 // Enable experiments for testing. | 165 // Enable experiments for testing. |
| 166 Runtime.experiments.enableForTest("disableAgentsWhenProfile"); |
166 var testPath = WebInspector.settings.testPath.get(); | 167 var testPath = WebInspector.settings.testPath.get(); |
167 if (testPath.indexOf("timeline/") !== -1 || testPath.indexOf("layers
/") !== -1) | 168 if (testPath.indexOf("timeline/") !== -1 || testPath.indexOf("layers
/") !== -1) |
168 Runtime.experiments.enableForTest("layersPanel"); | 169 Runtime.experiments.enableForTest("layersPanel"); |
169 if (testPath.indexOf("tracing/") !== -1) | 170 if (testPath.indexOf("tracing/") !== -1) |
170 Runtime.experiments.enableForTest("timelineOnTraceEvents"); | 171 Runtime.experiments.enableForTest("timelineOnTraceEvents"); |
171 if (testPath.indexOf("documentation/") !== -1) | 172 if (testPath.indexOf("documentation/") !== -1) |
172 Runtime.experiments.enableForTest("documentation"); | 173 Runtime.experiments.enableForTest("documentation"); |
173 } else { | 174 } else { |
174 Runtime.experiments.setDefaultExperiments(["timelineOnTraceEvents",
"timelineJSCPUProfile"]); | 175 Runtime.experiments.setDefaultExperiments([ |
| 176 "timelineOnTraceEvents", |
| 177 "disableAgentsWhenProfile", |
| 178 "timelineJSCPUProfile", |
| 179 ]); |
175 } | 180 } |
176 }, | 181 }, |
177 | 182 |
178 _createAppUI: function() | 183 _createAppUI: function() |
179 { | 184 { |
180 console.timeStamp("Main._createApp"); | 185 console.timeStamp("Main._createApp"); |
181 | 186 |
182 WebInspector.installPortStyles(); | 187 WebInspector.installPortStyles(); |
183 if (Runtime.queryParam("toolbarColor") && Runtime.queryParam("textColor"
)) | 188 if (Runtime.queryParam("toolbarColor") && Runtime.queryParam("textColor"
)) |
184 WebInspector.setToolbarColors(Runtime.queryParam("toolbarColor"), Ru
ntime.queryParam("textColor")); | 189 WebInspector.setToolbarColors(Runtime.queryParam("toolbarColor"), Ru
ntime.queryParam("textColor")); |
(...skipping 684 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
869 /** | 874 /** |
870 * @param {!WebInspector.Event} event | 875 * @param {!WebInspector.Event} event |
871 */ | 876 */ |
872 _inspectNode: function(event) | 877 _inspectNode: function(event) |
873 { | 878 { |
874 WebInspector.Revealer.reveal(/** @type {!WebInspector.DOMNode} */ (event
.data)); | 879 WebInspector.Revealer.reveal(/** @type {!WebInspector.DOMNode} */ (event
.data)); |
875 } | 880 } |
876 } | 881 } |
877 | 882 |
878 new WebInspector.Main(); | 883 new WebInspector.Main(); |
OLD | NEW |