OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * Copyright (C) 2012 Intel Inc. All rights reserved. | 3 * Copyright (C) 2012 Intel Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 1262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1273 WebInspector.TimelinePopupContentHelper.prototype = { | 1273 WebInspector.TimelinePopupContentHelper.prototype = { |
1274 /** | 1274 /** |
1275 * @return {!Element} | 1275 * @return {!Element} |
1276 */ | 1276 */ |
1277 contentTable: function() | 1277 contentTable: function() |
1278 { | 1278 { |
1279 return this._contentTable; | 1279 return this._contentTable; |
1280 }, | 1280 }, |
1281 | 1281 |
1282 /** | 1282 /** |
| 1283 * @param {string|number} content |
1283 * @param {string=} styleName | 1284 * @param {string=} styleName |
1284 */ | 1285 */ |
1285 _createCell: function(content, styleName) | 1286 _createCell: function(content, styleName) |
1286 { | 1287 { |
1287 var text = document.createElement("label"); | 1288 var text = document.createElement("label"); |
1288 text.appendChild(document.createTextNode(content)); | 1289 text.appendChild(document.createTextNode(content)); |
1289 var cell = document.createElement("td"); | 1290 var cell = document.createElement("td"); |
1290 cell.className = "timeline-details"; | 1291 cell.className = "timeline-details"; |
1291 if (styleName) | 1292 if (styleName) |
1292 cell.className += " " + styleName; | 1293 cell.className += " " + styleName; |
1293 cell.textContent = content; | 1294 cell.textContent = content; |
1294 return cell; | 1295 return cell; |
1295 }, | 1296 }, |
1296 | 1297 |
1297 /** | 1298 /** |
1298 * @param {string} title | 1299 * @param {string} title |
1299 * @param {string|number|boolean} content | 1300 * @param {string|number} content |
1300 */ | 1301 */ |
1301 appendTextRow: function(title, content) | 1302 appendTextRow: function(title, content) |
1302 { | 1303 { |
1303 var row = document.createElement("tr"); | 1304 var row = document.createElement("tr"); |
1304 row.appendChild(this._createCell(title, "timeline-details-row-title")); | 1305 row.appendChild(this._createCell(title, "timeline-details-row-title")); |
1305 row.appendChild(this._createCell(content, "timeline-details-row-data")); | 1306 row.appendChild(this._createCell(content, "timeline-details-row-data")); |
1306 this._contentTable.appendChild(row); | 1307 this._contentTable.appendChild(row); |
1307 }, | 1308 }, |
1308 | 1309 |
1309 /** | 1310 /** |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1396 for (var i = 0; i < stackTrace.length; ++i) { | 1397 for (var i = 0; i < stackTrace.length; ++i) { |
1397 var stackFrame = stackTrace[i]; | 1398 var stackFrame = stackTrace[i]; |
1398 var row = stackTraceElement.createChild("div"); | 1399 var row = stackTraceElement.createChild("div"); |
1399 row.createTextChild(stackFrame.functionName || WebInspector.UIString
("(anonymous function)")); | 1400 row.createTextChild(stackFrame.functionName || WebInspector.UIString
("(anonymous function)")); |
1400 row.createTextChild(" @ "); | 1401 row.createTextChild(" @ "); |
1401 var urlElement = this._linkifier.linkifyLocation(this._target, stack
Frame.url, stackFrame.lineNumber - 1); | 1402 var urlElement = this._linkifier.linkifyLocation(this._target, stack
Frame.url, stackFrame.lineNumber - 1); |
1402 row.appendChild(urlElement); | 1403 row.appendChild(urlElement); |
1403 } | 1404 } |
1404 } | 1405 } |
1405 } | 1406 } |
OLD | NEW |