OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
3 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 3 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
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 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
255 { | 255 { |
256 console.assert(this._linkifier); | 256 console.assert(this._linkifier); |
257 var target = this._target(); | 257 var target = this._target(); |
258 if (!this._linkifier || !target) | 258 if (!this._linkifier || !target) |
259 return null; | 259 return null; |
260 // FIXME(62725): stack trace line/column numbers are one-based. | 260 // FIXME(62725): stack trace line/column numbers are one-based. |
261 lineNumber = lineNumber ? lineNumber - 1 : 0; | 261 lineNumber = lineNumber ? lineNumber - 1 : 0; |
262 columnNumber = columnNumber ? columnNumber - 1 : 0; | 262 columnNumber = columnNumber ? columnNumber - 1 : 0; |
263 if (this._message.source === WebInspector.ConsoleMessage.MessageSource.C SS) { | 263 if (this._message.source === WebInspector.ConsoleMessage.MessageSource.C SS) { |
264 var headerIds = target.cssModel.styleSheetIdsForURL(url); | 264 var headerIds = target.cssModel.styleSheetIdsForURL(url); |
265 var cssLocation = new WebInspector.CSSLocation(target, url, lineNumb er, columnNumber); | 265 console.assert(headerIds[0]); |
vsevik
2014/07/18 15:45:37
Please revert this
| |
266 return this._linkifier.linkifyCSSLocation(headerIds[0] || null, cssL ocation, "console-message-url"); | 266 var cssLocation = new WebInspector.CSSLocation(target, headerIds[0], url, lineNumber, columnNumber); |
267 return this._linkifier.linkifyCSSLocation(cssLocation, "console-mess age-url"); | |
267 } | 268 } |
268 | 269 |
269 return this._linkifier.linkifyLocation(target, url, lineNumber, columnNu mber, "console-message-url"); | 270 return this._linkifier.linkifyLocation(target, url, lineNumber, columnNu mber, "console-message-url"); |
270 }, | 271 }, |
271 | 272 |
272 /** | 273 /** |
273 * @param {!ConsoleAgent.CallFrame} callFrame | 274 * @param {!ConsoleAgent.CallFrame} callFrame |
274 * @return {?Element} | 275 * @return {?Element} |
275 */ | 276 */ |
276 _linkifyCallFrame: function(callFrame) | 277 _linkifyCallFrame: function(callFrame) |
(...skipping 984 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1261 { | 1262 { |
1262 if (!this._wrapperElement) { | 1263 if (!this._wrapperElement) { |
1263 WebInspector.ConsoleViewMessage.prototype.toMessageElement.call(this ); | 1264 WebInspector.ConsoleViewMessage.prototype.toMessageElement.call(this ); |
1264 this._wrapperElement.classList.toggle("collapsed", this._collapsed); | 1265 this._wrapperElement.classList.toggle("collapsed", this._collapsed); |
1265 } | 1266 } |
1266 return this._wrapperElement; | 1267 return this._wrapperElement; |
1267 }, | 1268 }, |
1268 | 1269 |
1269 __proto__: WebInspector.ConsoleViewMessage.prototype | 1270 __proto__: WebInspector.ConsoleViewMessage.prototype |
1270 } | 1271 } |
OLD | NEW |