| 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 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 148 | 148 |
| 149 if (sourceMap) | 149 if (sourceMap) |
| 150 this._sourceMapByURL[completeSourceMapURL] = sourceMap; | 150 this._sourceMapByURL[completeSourceMapURL] = sourceMap; |
| 151 else | 151 else |
| 152 delete this._sourceMapByURL[completeSourceMapURL]; | 152 delete this._sourceMapByURL[completeSourceMapURL]; |
| 153 | 153 |
| 154 // Then report sources. | 154 // Then report sources. |
| 155 var sources = sourceMap ? sourceMap.sources() : []; | 155 var sources = sourceMap ? sourceMap.sources() : []; |
| 156 for (var i = 0; i < sources.length; ++i) { | 156 for (var i = 0; i < sources.length; ++i) { |
| 157 var sassURL = sources[i]; | 157 var sassURL = sources[i]; |
| 158 if (!this._networkMapping.hasMappingForURL(sassURL)) { | 158 if (!this._networkMapping.hasMappingForNetworkURL(sassURL)) { |
| 159 var contentProvider = sourceMap.sourceContentProvider(sassUR
L, WebInspector.resourceTypes.SourceMapStyleSheet); | 159 var contentProvider = sourceMap.sourceContentProvider(sassUR
L, WebInspector.resourceTypes.SourceMapStyleSheet); |
| 160 this._networkProject.addFileForURL(sassURL, contentProvider,
WebInspector.ResourceTreeFrame.fromStyleSheet(header)); | 160 this._networkProject.addFileForURL(sassURL, contentProvider,
WebInspector.ResourceTreeFrame.fromStyleSheet(header)); |
| 161 } | 161 } |
| 162 } | 162 } |
| 163 | 163 |
| 164 for (var i = 0; callbacks && i < callbacks.length; ++i) | 164 for (var i = 0; callbacks && i < callbacks.length; ++i) |
| 165 callbacks[i](sourceMap); | 165 callbacks[i](sourceMap); |
| 166 } | 166 } |
| 167 }, | 167 }, |
| 168 | 168 |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 227 | 227 |
| 228 _reset: function() | 228 _reset: function() |
| 229 { | 229 { |
| 230 /** @type {!Object.<string, !Array.<function(?WebInspector.SourceMap)>>}
*/ | 230 /** @type {!Object.<string, !Array.<function(?WebInspector.SourceMap)>>}
*/ |
| 231 this._pendingSourceMapLoadingCallbacks = {}; | 231 this._pendingSourceMapLoadingCallbacks = {}; |
| 232 /** @type {!Object.<string, !WebInspector.SourceMap>} */ | 232 /** @type {!Object.<string, !WebInspector.SourceMap>} */ |
| 233 this._sourceMapByURL = {}; | 233 this._sourceMapByURL = {}; |
| 234 this._sourceMapByStyleSheetURL = {}; | 234 this._sourceMapByStyleSheetURL = {}; |
| 235 } | 235 } |
| 236 } | 236 } |
| OLD | NEW |