| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 constructor(targetManager, workspace) { | 39 constructor(targetManager, workspace) { |
| 40 this._workspace = workspace; | 40 this._workspace = workspace; |
| 41 targetManager.observeTargets(this); | 41 targetManager.observeTargets(this); |
| 42 } | 42 } |
| 43 | 43 |
| 44 /** | 44 /** |
| 45 * @override | 45 * @override |
| 46 * @param {!SDK.Target} target | 46 * @param {!SDK.Target} target |
| 47 */ | 47 */ |
| 48 targetAdded(target) { | 48 targetAdded(target) { |
| 49 new Bindings.NetworkProject(target, this._workspace, SDK.ResourceTreeModel.f
romTarget(target)); | 49 new Bindings.NetworkProject(target, this._workspace, target.model(SDK.Resour
ceTreeModel)); |
| 50 } | 50 } |
| 51 | 51 |
| 52 /** | 52 /** |
| 53 * @override | 53 * @override |
| 54 * @param {!SDK.Target} target | 54 * @param {!SDK.Target} target |
| 55 */ | 55 */ |
| 56 targetRemoved(target) { | 56 targetRemoved(target) { |
| 57 Bindings.NetworkProject.forTarget(target)._dispose(); | 57 Bindings.NetworkProject.forTarget(target)._dispose(); |
| 58 } | 58 } |
| 59 }; | 59 }; |
| (...skipping 370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 430 workspace.uiSourceCode(Bindings.NetworkProject.projectId(target, frameId
, true), url); | 430 workspace.uiSourceCode(Bindings.NetworkProject.projectId(target, frameId
, true), url); |
| 431 } | 431 } |
| 432 | 432 |
| 433 /** | 433 /** |
| 434 * @param {!Workspace.Workspace} workspace | 434 * @param {!Workspace.Workspace} workspace |
| 435 * @param {string} url | 435 * @param {string} url |
| 436 * @param {!SDK.CSSStyleSheetHeader} header | 436 * @param {!SDK.CSSStyleSheetHeader} header |
| 437 * @return {?Workspace.UISourceCode} | 437 * @return {?Workspace.UISourceCode} |
| 438 */ | 438 */ |
| 439 static uiSourceCodeForStyleURL(workspace, url, header) { | 439 static uiSourceCodeForStyleURL(workspace, url, header) { |
| 440 return workspace.uiSourceCode(Bindings.NetworkProject.projectId(header.targe
t(), header.frameId, false), url); | 440 return workspace.uiSourceCode( |
| 441 Bindings.NetworkProject.projectId(header.cssModel().target(), header.fra
meId, false), url); |
| 441 } | 442 } |
| 442 }; | 443 }; |
| 443 | 444 |
| 444 Bindings.NetworkProject._networkProjectSymbol = Symbol('networkProject'); | 445 Bindings.NetworkProject._networkProjectSymbol = Symbol('networkProject'); |
| 445 Bindings.NetworkProject._resourceSymbol = Symbol('resource'); | 446 Bindings.NetworkProject._resourceSymbol = Symbol('resource'); |
| 446 Bindings.NetworkProject._scriptSymbol = Symbol('script'); | 447 Bindings.NetworkProject._scriptSymbol = Symbol('script'); |
| 447 Bindings.NetworkProject._styleSheetSymbol = Symbol('styleSheet'); | 448 Bindings.NetworkProject._styleSheetSymbol = Symbol('styleSheet'); |
| 448 Bindings.NetworkProject._targetSymbol = Symbol('target'); | 449 Bindings.NetworkProject._targetSymbol = Symbol('target'); |
| 449 Bindings.NetworkProject._frameSymbol = Symbol('frame'); | 450 Bindings.NetworkProject._frameSymbol = Symbol('frame'); |
| OLD | NEW |