| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2014 Google Inc. All rights reserved. | 2 * Copyright (C) 2014 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 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 */ | 104 */ |
| 105 entryTitle: function(entryIndex) | 105 entryTitle: function(entryIndex) |
| 106 { | 106 { |
| 107 var event = this._entryEvents[entryIndex]; | 107 var event = this._entryEvents[entryIndex]; |
| 108 if (event) { | 108 if (event) { |
| 109 if (event.phase === WebInspector.TracingModel.Phase.AsyncStepInto ||
event.phase === WebInspector.TracingModel.Phase.AsyncStepPast) | 109 if (event.phase === WebInspector.TracingModel.Phase.AsyncStepInto ||
event.phase === WebInspector.TracingModel.Phase.AsyncStepPast) |
| 110 return event.name + ":" + event.args["step"]; | 110 return event.name + ":" + event.args["step"]; |
| 111 | 111 |
| 112 var name = WebInspector.TimelineUIUtils.eventStyle(event).title; | 112 var name = WebInspector.TimelineUIUtils.eventStyle(event).title; |
| 113 // TODO(yurys): support event dividers | 113 // TODO(yurys): support event dividers |
| 114 var details = WebInspector.TimelineUIUtils.buildDetailsNodeForTraceE
vent(event, this._linkifier); | 114 var details = WebInspector.TimelineUIUtils.buildDetailsNodeForTraceE
vent(event, this._model.target(), this._linkifier); |
| 115 if (event.name === WebInspector.TimelineModel.RecordType.JSFrame &&
details) | 115 if (event.name === WebInspector.TimelineModel.RecordType.JSFrame &&
details) |
| 116 return details.textContent; | 116 return details.textContent; |
| 117 return details ? WebInspector.UIString("%s (%s)", name, details.text
Content) : name; | 117 return details ? WebInspector.UIString("%s (%s)", name, details.text
Content) : name; |
| 118 } | 118 } |
| 119 var title = this._entryIndexToTitle[entryIndex]; | 119 var title = this._entryIndexToTitle[entryIndex]; |
| 120 if (!title) { | 120 if (!title) { |
| 121 title = WebInspector.UIString("Unexpected entryIndex %d", entryIndex
); | 121 title = WebInspector.UIString("Unexpected entryIndex %d", entryIndex
); |
| 122 console.error(title); | 122 console.error(title); |
| 123 } | 123 } |
| 124 return title; | 124 return title; |
| (...skipping 663 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 788 /** | 788 /** |
| 789 * @constructor | 789 * @constructor |
| 790 * @param {!WebInspector.TimelineSelection} selection | 790 * @param {!WebInspector.TimelineSelection} selection |
| 791 * @param {number} entryIndex | 791 * @param {number} entryIndex |
| 792 */ | 792 */ |
| 793 WebInspector.TimelineFlameChart.Selection = function(selection, entryIndex) | 793 WebInspector.TimelineFlameChart.Selection = function(selection, entryIndex) |
| 794 { | 794 { |
| 795 this.timelineSelection = selection; | 795 this.timelineSelection = selection; |
| 796 this.entryIndex = entryIndex; | 796 this.entryIndex = entryIndex; |
| 797 } | 797 } |
| OLD | NEW |