Chromium Code Reviews| 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 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 180 this._loadSourceMapForScript(script, this._sourceMapLoaded.bind(this, sc ript, stubUISourceCode.url())); | 180 this._loadSourceMapForScript(script, this._sourceMapLoaded.bind(this, sc ript, stubUISourceCode.url())); |
| 181 }, | 181 }, |
| 182 | 182 |
| 183 /** | 183 /** |
| 184 * @param {!WebInspector.Script} script | 184 * @param {!WebInspector.Script} script |
| 185 * @param {string} uiSourceCodePath | 185 * @param {string} uiSourceCodePath |
| 186 * @param {?WebInspector.SourceMap} sourceMap | 186 * @param {?WebInspector.SourceMap} sourceMap |
| 187 */ | 187 */ |
| 188 _sourceMapLoaded: function(script, uiSourceCodePath, sourceMap) | 188 _sourceMapLoaded: function(script, uiSourceCodePath, sourceMap) |
| 189 { | 189 { |
| 190 script.dispatchEventToListeners(WebInspector.Script.Events.SourceMapLoad ed, sourceMap); | |
|
dgozman
2016/02/03 18:24:10
Just make a direct call into BlackboxManager.
kozy
2016/02/09 23:10:09
Done.
| |
| 191 | |
| 190 this._stubUISourceCodes.delete(script.scriptId); | 192 this._stubUISourceCodes.delete(script.scriptId); |
| 191 this._stubProject.removeFile(uiSourceCodePath); | 193 this._stubProject.removeFile(uiSourceCodePath); |
| 192 | 194 |
| 193 if (!sourceMap) { | 195 if (!sourceMap) { |
| 194 this._debuggerWorkspaceBinding.updateLocations(script); | 196 this._debuggerWorkspaceBinding.updateLocations(script); |
| 195 return; | 197 return; |
| 196 } | 198 } |
| 197 | 199 |
| 198 if (this._scriptForSourceMap.get(sourceMap)) { | 200 if (this._scriptForSourceMap.get(sourceMap)) { |
| 199 this._sourceMapForScriptId[script.scriptId] = sourceMap; | 201 this._sourceMapForScriptId[script.scriptId] = sourceMap; |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 373 this._sourceMapForScriptId = {}; | 375 this._sourceMapForScriptId = {}; |
| 374 this._scriptForSourceMap.clear(); | 376 this._scriptForSourceMap.clear(); |
| 375 this._sourceMapForURL.clear(); | 377 this._sourceMapForURL.clear(); |
| 376 }, | 378 }, |
| 377 | 379 |
| 378 dispose: function() | 380 dispose: function() |
| 379 { | 381 { |
| 380 this._workspace.removeEventListener(WebInspector.Workspace.Events.UISour ceCodeAdded, this._uiSourceCodeAddedToWorkspace, this); | 382 this._workspace.removeEventListener(WebInspector.Workspace.Events.UISour ceCodeAdded, this._uiSourceCodeAddedToWorkspace, this); |
| 381 } | 383 } |
| 382 } | 384 } |
| OLD | NEW |