| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 /** | 5 /** |
| 6 * @implements {PerfUI.FlameChartDataProvider} | 6 * @implements {PerfUI.FlameChartDataProvider} |
| 7 * @unrestricted | 7 * @unrestricted |
| 8 */ | 8 */ |
| 9 Timeline.TimelineFlameChartNetworkDataProvider = class { | 9 Timeline.TimelineFlameChartNetworkDataProvider = class { |
| 10 constructor() { | 10 constructor() { |
| (...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 280 return null; | 280 return null; |
| 281 var element = createElement('div'); | 281 var element = createElement('div'); |
| 282 var root = UI.createShadowRootWithCoreStyles(element, 'timeline/timelineFlam
echartPopover.css'); | 282 var root = UI.createShadowRootWithCoreStyles(element, 'timeline/timelineFlam
echartPopover.css'); |
| 283 var contents = root.createChild('div', 'timeline-flamechart-popover'); | 283 var contents = root.createChild('div', 'timeline-flamechart-popover'); |
| 284 var duration = request.endTime - request.startTime; | 284 var duration = request.endTime - request.startTime; |
| 285 if (request.startTime && isFinite(duration)) | 285 if (request.startTime && isFinite(duration)) |
| 286 contents.createChild('span', 'timeline-info-network-time').textContent = N
umber.millisToString(duration); | 286 contents.createChild('span', 'timeline-info-network-time').textContent = N
umber.millisToString(duration); |
| 287 if (typeof request.priority === 'string') { | 287 if (typeof request.priority === 'string') { |
| 288 var div = contents.createChild('span'); | 288 var div = contents.createChild('span'); |
| 289 div.textContent = | 289 div.textContent = |
| 290 NetworkConditions.uiLabelForPriority(/** @type {!Protocol.Network.Reso
urcePriority} */ (request.priority)); | 290 NetworkPriorities.uiLabelForPriority(/** @type {!Protocol.Network.Reso
urcePriority} */ (request.priority)); |
| 291 div.style.color = this._colorForPriority(request.priority) || 'black'; | 291 div.style.color = this._colorForPriority(request.priority) || 'black'; |
| 292 } | 292 } |
| 293 contents.createChild('span').textContent = request.url.trimMiddle(maxURLChar
s); | 293 contents.createChild('span').textContent = request.url.trimMiddle(maxURLChar
s); |
| 294 return element; | 294 return element; |
| 295 } | 295 } |
| 296 | 296 |
| 297 /** | 297 /** |
| 298 * @param {string} priority | 298 * @param {string} priority |
| 299 * @return {?string} | 299 * @return {?string} |
| 300 */ | 300 */ |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 386 | 386 |
| 387 /** | 387 /** |
| 388 * @override | 388 * @override |
| 389 * @param {number} entryIndex | 389 * @param {number} entryIndex |
| 390 * @return {boolean} | 390 * @return {boolean} |
| 391 */ | 391 */ |
| 392 canJumpToEntry(entryIndex) { | 392 canJumpToEntry(entryIndex) { |
| 393 return false; | 393 return false; |
| 394 } | 394 } |
| 395 }; | 395 }; |
| OLD | NEW |