| 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 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 if (record.type === WebInspector.TimelineModel.RecordType.GPUTask ||
!!record.thread) | 193 if (record.type === WebInspector.TimelineModel.RecordType.GPUTask ||
!!record.thread) |
| 194 return; | 194 return; |
| 195 } else { | 195 } else { |
| 196 if (record.type === WebInspector.TimelineModel.RecordType.Program ||
!record.thread) | 196 if (record.type === WebInspector.TimelineModel.RecordType.Program ||
!record.thread) |
| 197 return; | 197 return; |
| 198 } | 198 } |
| 199 | 199 |
| 200 var index = this._entryTitles.length; | 200 var index = this._entryTitles.length; |
| 201 this._entryTitles[index] = record.type; | 201 this._entryTitles[index] = record.type; |
| 202 timelineData.entryOffsets[index] = record.startTime - startTime; | 202 timelineData.entryOffsets[index] = record.startTime - startTime; |
| 203 timelineData.entryLevels[index] = depth - 1; | 203 timelineData.entryLevels[index] = depth; |
| 204 timelineData.entryTotalTimes[index] = endTime - record.startTime; | 204 timelineData.entryTotalTimes[index] = endTime - record.startTime; |
| 205 this._entryColors[index] = this._colorGenerator.colorForID(WebInspector.
TimelineUIUtils.categoryForRecord(record).name); | 205 this._entryColors[index] = this._colorGenerator.colorForID(WebInspector.
TimelineUIUtils.categoryForRecord(record).name); |
| 206 this._maxStackDepth = Math.max(this._maxStackDepth, depth + 1); | 206 this._maxStackDepth = Math.max(this._maxStackDepth, depth + 1); |
| 207 }, | 207 }, |
| 208 | 208 |
| 209 /** | 209 /** |
| 210 * @param {number} entryIndex | 210 * @param {number} entryIndex |
| 211 * @return {?Array.<!{title: string, text: string}>} | 211 * @return {?Array.<!{title: string, text: string}>} |
| 212 */ | 212 */ |
| 213 prepareHighlightedEntryInfo: function(entryIndex) | 213 prepareHighlightedEntryInfo: function(entryIndex) |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 267 WebInspector.TimelineFlameChart.prototype = { | 267 WebInspector.TimelineFlameChart.prototype = { |
| 268 /** | 268 /** |
| 269 * @param {number} windowStartTime | 269 * @param {number} windowStartTime |
| 270 * @param {number} windowEndTime | 270 * @param {number} windowEndTime |
| 271 */ | 271 */ |
| 272 requestWindowTimes: function(windowStartTime, windowEndTime) | 272 requestWindowTimes: function(windowStartTime, windowEndTime) |
| 273 { | 273 { |
| 274 this._delegate.requestWindowTimes(windowStartTime, windowEndTime); | 274 this._delegate.requestWindowTimes(windowStartTime, windowEndTime); |
| 275 }, | 275 }, |
| 276 | 276 |
| 277 refreshRecords: function() | 277 /** |
| 278 * @param {?RegExp} textFilter |
| 279 */ |
| 280 refreshRecords: function(textFilter) |
| 278 { | 281 { |
| 282 this._dataProvider.reset(); |
| 283 this._mainView._scheduleUpdate(); |
| 279 }, | 284 }, |
| 280 | 285 |
| 281 reset: function() | 286 reset: function() |
| 282 { | 287 { |
| 283 this._automaticallySizeWindow = true; | 288 this._automaticallySizeWindow = true; |
| 284 this._dataProvider.reset(); | 289 this._dataProvider.reset(); |
| 285 this._mainView.setWindowTimes(0, Infinity); | 290 this._mainView.setWindowTimes(0, Infinity); |
| 286 }, | 291 }, |
| 287 | 292 |
| 288 _onRecordingStarted: function() | 293 _onRecordingStarted: function() |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 344 }, | 349 }, |
| 345 | 350 |
| 346 /** | 351 /** |
| 347 * @param {?WebInspector.TimelineModel.Record} record | 352 * @param {?WebInspector.TimelineModel.Record} record |
| 348 */ | 353 */ |
| 349 setSelectedRecord: function(record) | 354 setSelectedRecord: function(record) |
| 350 { | 355 { |
| 351 }, | 356 }, |
| 352 | 357 |
| 353 __proto__: WebInspector.View.prototype | 358 __proto__: WebInspector.View.prototype |
| 354 } | 359 } |
| OLD | NEW |