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 307 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
318 this._mainTarget = WebInspector.targetManager.createTarget(WebInspector.
UIString("Main"), capabilities, connection, null); | 318 this._mainTarget = WebInspector.targetManager.createTarget(WebInspector.
UIString("Main"), capabilities, connection, null); |
319 console.timeStamp("Main._mainTargetCreated"); | 319 console.timeStamp("Main._mainTargetCreated"); |
320 this._registerShortcuts(); | 320 this._registerShortcuts(); |
321 | 321 |
322 this._mainTarget.registerInspectorDispatcher(this); | 322 this._mainTarget.registerInspectorDispatcher(this); |
323 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.E
vents.ReloadInspectedPage, this._reloadInspectedPage, this); | 323 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.E
vents.ReloadInspectedPage, this._reloadInspectedPage, this); |
324 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.E
vents.EvaluateForTestInFrontend, this._evaluateForTestInFrontend, this); | 324 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.E
vents.EvaluateForTestInFrontend, this._evaluateForTestInFrontend, this); |
325 | 325 |
326 this._mainTarget.runtimeAgent().run(); | 326 this._mainTarget.runtimeAgent().run(); |
327 | 327 |
328 this._mainTarget.inspectorAgent().enable(); | 328 if (this._mainTarget.hasBrowserCapability()) |
| 329 this._mainTarget.inspectorAgent().enable(); |
329 InspectorFrontendHost.readyForTest(); | 330 InspectorFrontendHost.readyForTest(); |
330 | 331 |
331 // Asynchronously run the extensions. | 332 // Asynchronously run the extensions. |
332 setTimeout(lateInitialization, 0); | 333 setTimeout(lateInitialization, 0); |
333 | 334 |
334 function lateInitialization() | 335 function lateInitialization() |
335 { | 336 { |
336 console.timeStamp("Main.lateInitialization"); | 337 console.timeStamp("Main.lateInitialization"); |
337 WebInspector.extensionServer.initializeExtensions(); | 338 WebInspector.extensionServer.initializeExtensions(); |
338 } | 339 } |
(...skipping 752 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1091 * @return {?Element} | 1092 * @return {?Element} |
1092 */ | 1093 */ |
1093 settingElement: function() | 1094 settingElement: function() |
1094 { | 1095 { |
1095 return WebInspector.SettingsUI.createSettingCheckbox(WebInspector.UIStri
ng("Show rulers"), WebInspector.moduleSetting("showMetricsRulers")); | 1096 return WebInspector.SettingsUI.createSettingCheckbox(WebInspector.UIStri
ng("Show rulers"), WebInspector.moduleSetting("showMetricsRulers")); |
1096 } | 1097 } |
1097 } | 1098 } |
1098 | 1099 |
1099 | 1100 |
1100 new WebInspector.Main(); | 1101 new WebInspector.Main(); |
OLD | NEW |