Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(301)

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js

Issue 2501883002: DevTools: kill Bindings.NetworkMapping (Closed)
Patch Set: rebaseline Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 * @implements {SDK.TargetManager.Observer} 5 * @implements {SDK.TargetManager.Observer}
6 * @unrestricted 6 * @unrestricted
7 */ 7 */
8 Bindings.DebuggerWorkspaceBinding = class { 8 Bindings.DebuggerWorkspaceBinding = class {
9 /** 9 /**
10 * @param {!SDK.TargetManager} targetManager 10 * @param {!SDK.TargetManager} targetManager
11 * @param {!Workspace.Workspace} workspace 11 * @param {!Workspace.Workspace} workspace
12 * @param {!Bindings.NetworkMapping} networkMapping
13 */ 12 */
14 constructor(targetManager, workspace, networkMapping) { 13 constructor(targetManager, workspace) {
15 this._workspace = workspace; 14 this._workspace = workspace;
16 this._networkMapping = networkMapping;
17 15
18 // FIXME: Migrate from _targetToData to _debuggerModelToData. 16 // FIXME: Migrate from _targetToData to _debuggerModelToData.
19 /** @type {!Map.<!SDK.Target, !Bindings.DebuggerWorkspaceBinding.TargetData> } */ 17 /** @type {!Map.<!SDK.Target, !Bindings.DebuggerWorkspaceBinding.TargetData> } */
20 this._targetToData = new Map(); 18 this._targetToData = new Map();
21 targetManager.observeTargets(this); 19 targetManager.observeTargets(this);
22 20
23 targetManager.addModelListener( 21 targetManager.addModelListener(
24 SDK.DebuggerModel, SDK.DebuggerModel.Events.GlobalObjectCleared, this._g lobalObjectCleared, this); 22 SDK.DebuggerModel, SDK.DebuggerModel.Events.GlobalObjectCleared, this._g lobalObjectCleared, this);
25 targetManager.addModelListener( 23 targetManager.addModelListener(
26 SDK.DebuggerModel, SDK.DebuggerModel.Events.BeforeDebuggerPaused, this._ beforeDebuggerPaused, this); 24 SDK.DebuggerModel, SDK.DebuggerModel.Events.BeforeDebuggerPaused, this._ beforeDebuggerPaused, this);
(...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after
354 constructor(debuggerModel, debuggerWorkspaceBinding) { 352 constructor(debuggerModel, debuggerWorkspaceBinding) {
355 this._target = debuggerModel.target(); 353 this._target = debuggerModel.target();
356 354
357 /** @type {!Map.<string, !Bindings.DebuggerWorkspaceBinding.ScriptInfo>} */ 355 /** @type {!Map.<string, !Bindings.DebuggerWorkspaceBinding.ScriptInfo>} */
358 this.scriptDataMap = new Map(); 356 this.scriptDataMap = new Map();
359 357
360 /** @type {!Set.<!Bindings.DebuggerWorkspaceBinding.Location>} */ 358 /** @type {!Set.<!Bindings.DebuggerWorkspaceBinding.Location>} */
361 this.callFrameLocations = new Set(); 359 this.callFrameLocations = new Set();
362 360
363 var workspace = debuggerWorkspaceBinding._workspace; 361 var workspace = debuggerWorkspaceBinding._workspace;
364 var networkMapping = debuggerWorkspaceBinding._networkMapping;
365 362
366 this._defaultMapping = new Bindings.DefaultScriptMapping(debuggerModel, work space, debuggerWorkspaceBinding); 363 this._defaultMapping = new Bindings.DefaultScriptMapping(debuggerModel, work space, debuggerWorkspaceBinding);
367 this._resourceMapping = 364 this._resourceMapping =
368 new Bindings.ResourceScriptMapping(debuggerModel, workspace, networkMapp ing, debuggerWorkspaceBinding); 365 new Bindings.ResourceScriptMapping(debuggerModel, workspace, debuggerWor kspaceBinding);
369 this._compilerMapping = new Bindings.CompilerScriptMapping( 366 this._compilerMapping = new Bindings.CompilerScriptMapping(
370 debuggerModel, workspace, networkMapping, Bindings.NetworkProject.forTar get(this._target), 367 debuggerModel, workspace, Bindings.NetworkProject.forTarget(this._target ),
371 debuggerWorkspaceBinding); 368 debuggerWorkspaceBinding);
372 369
373 /** @type {!Map.<!Workspace.UISourceCode, !Bindings.DebuggerSourceMapping>} */ 370 /** @type {!Map.<!Workspace.UISourceCode, !Bindings.DebuggerSourceMapping>} */
374 this._uiSourceCodeToSourceMapping = new Map(); 371 this._uiSourceCodeToSourceMapping = new Map();
375 372
376 this._eventListeners = [ 373 this._eventListeners = [
377 debuggerModel.addEventListener(SDK.DebuggerModel.Events.ParsedScriptSource , this._parsedScriptSource, this), 374 debuggerModel.addEventListener(SDK.DebuggerModel.Events.ParsedScriptSource , this._parsedScriptSource, this),
378 debuggerModel.addEventListener(SDK.DebuggerModel.Events.FailedToParseScrip tSource, this._parsedScriptSource, this) 375 debuggerModel.addEventListener(SDK.DebuggerModel.Events.FailedToParseScrip tSource, this._parsedScriptSource, this)
379 ]; 376 ];
380 } 377 }
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
653 * @param {number} lineNumber 650 * @param {number} lineNumber
654 * @return {boolean} 651 * @return {boolean}
655 */ 652 */
656 uiLineHasMapping: function(uiSourceCode, lineNumber) {} 653 uiLineHasMapping: function(uiSourceCode, lineNumber) {}
657 }; 654 };
658 655
659 /** 656 /**
660 * @type {!Bindings.DebuggerWorkspaceBinding} 657 * @type {!Bindings.DebuggerWorkspaceBinding}
661 */ 658 */
662 Bindings.debuggerWorkspaceBinding; 659 Bindings.debuggerWorkspaceBinding;
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698