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 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 | 259 |
260 InspectorBackend.setConnection(connection); | 260 InspectorBackend.setConnection(connection); |
261 | 261 |
262 // Install styles and themes | 262 // Install styles and themes |
263 WebInspector.installPortStyles(); | 263 WebInspector.installPortStyles(); |
264 | 264 |
265 if (WebInspector.queryParam("toolbarColor") && WebInspector.queryParam("
textColor")) | 265 if (WebInspector.queryParam("toolbarColor") && WebInspector.queryParam("
textColor")) |
266 WebInspector.setToolbarColors(WebInspector.queryParam("toolbarColor"
), WebInspector.queryParam("textColor")); | 266 WebInspector.setToolbarColors(WebInspector.queryParam("toolbarColor"
), WebInspector.queryParam("textColor")); |
267 | 267 |
268 WebInspector.targetManager = new WebInspector.TargetManager(); | 268 WebInspector.targetManager = new WebInspector.TargetManager(); |
269 WebInspector.targetManager.createTarget(connection, this._doLoadedDoneWi
thCapabilities.bind(this)); | 269 WebInspector.targetManager.createTarget(WebInspector.UIString("Main"), c
onnection, this._doLoadedDoneWithCapabilities.bind(this)); |
270 WebInspector.isolatedFileSystemManager = new WebInspector.IsolatedFileSy
stemManager(); | 270 WebInspector.isolatedFileSystemManager = new WebInspector.IsolatedFileSy
stemManager(); |
271 WebInspector.isolatedFileSystemDispatcher = new WebInspector.IsolatedFil
eSystemDispatcher(WebInspector.isolatedFileSystemManager); | 271 WebInspector.isolatedFileSystemDispatcher = new WebInspector.IsolatedFil
eSystemDispatcher(WebInspector.isolatedFileSystemManager); |
272 WebInspector.workspace = new WebInspector.Workspace(WebInspector.isolate
dFileSystemManager.mapping()); | 272 WebInspector.workspace = new WebInspector.Workspace(WebInspector.isolate
dFileSystemManager.mapping()); |
273 WebInspector.networkWorkspaceBinding = new WebInspector.NetworkWorkspace
Binding(WebInspector.workspace); | 273 WebInspector.networkWorkspaceBinding = new WebInspector.NetworkWorkspace
Binding(WebInspector.workspace); |
274 new WebInspector.NetworkUISourceCodeProvider(WebInspector.networkWorkspa
ceBinding, WebInspector.workspace); | 274 new WebInspector.NetworkUISourceCodeProvider(WebInspector.networkWorkspa
ceBinding, WebInspector.workspace); |
275 new WebInspector.PresentationConsoleMessageHelper(WebInspector.workspace
); | 275 new WebInspector.PresentationConsoleMessageHelper(WebInspector.workspace
); |
276 WebInspector.fileSystemWorkspaceBinding = new WebInspector.FileSystemWor
kspaceBinding(WebInspector.isolatedFileSystemManager, WebInspector.workspace); | 276 WebInspector.fileSystemWorkspaceBinding = new WebInspector.FileSystemWor
kspaceBinding(WebInspector.isolatedFileSystemManager, WebInspector.workspace); |
277 WebInspector.breakpointManager = new WebInspector.BreakpointManager(WebI
nspector.settings.breakpoints, WebInspector.workspace, WebInspector.targetManage
r); | 277 WebInspector.breakpointManager = new WebInspector.BreakpointManager(WebI
nspector.settings.breakpoints, WebInspector.workspace, WebInspector.targetManage
r); |
278 WebInspector.scriptSnippetModel = new WebInspector.ScriptSnippetModel(We
bInspector.workspace); | 278 WebInspector.scriptSnippetModel = new WebInspector.ScriptSnippetModel(We
bInspector.workspace); |
279 this._executionContextSelector = new WebInspector.ExecutionContextSelect
or(); | 279 this._executionContextSelector = new WebInspector.ExecutionContextSelect
or(); |
(...skipping 518 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
798 /** | 798 /** |
799 * @param {string} ws | 799 * @param {string} ws |
800 */ | 800 */ |
801 WebInspector.Main._addWebSocketTarget = function(ws) | 801 WebInspector.Main._addWebSocketTarget = function(ws) |
802 { | 802 { |
803 /** | 803 /** |
804 * @param {!InspectorBackendClass.Connection} connection | 804 * @param {!InspectorBackendClass.Connection} connection |
805 */ | 805 */ |
806 function callback(connection) | 806 function callback(connection) |
807 { | 807 { |
808 WebInspector.targetManager.createTarget(connection); | 808 WebInspector.targetManager.createTarget(ws, connection); |
809 } | 809 } |
810 new InspectorBackendClass.WebSocketConnection(ws, callback); | 810 new InspectorBackendClass.WebSocketConnection(ws, callback); |
811 } | 811 } |
812 | 812 |
813 new WebInspector.Main(); | 813 new WebInspector.Main(); |
814 | 814 |
815 // These methods are added for backwards compatibility with Devtools CodeSchool
extension. | 815 // These methods are added for backwards compatibility with Devtools CodeSchool
extension. |
816 // DO NOT REMOVE | 816 // DO NOT REMOVE |
817 | 817 |
818 WebInspector.__defineGetter__("inspectedPageURL", function() | 818 WebInspector.__defineGetter__("inspectedPageURL", function() |
819 { | 819 { |
820 return WebInspector.resourceTreeModel.inspectedPageURL(); | 820 return WebInspector.resourceTreeModel.inspectedPageURL(); |
821 }); | 821 }); |
822 | 822 |
823 /** | 823 /** |
824 * @param {string} name | 824 * @param {string} name |
825 * @return {?WebInspector.Panel} | 825 * @return {?WebInspector.Panel} |
826 */ | 826 */ |
827 WebInspector.panel = function(name) | 827 WebInspector.panel = function(name) |
828 { | 828 { |
829 return WebInspector.inspectorView.panel(name); | 829 return WebInspector.inspectorView.panel(name); |
830 } | 830 } |
OLD | NEW |