Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1107)

Unified Diff: third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js

Issue 2668413003: DevTools: extract NetworkConditionsSelector into its own module (Closed)
Patch Set: rebaseline Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js
diff --git a/third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js b/third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js
index 9a7d7652820ced2566ae63aee85d18f5dce4557e..f9b43f41b57a78bbfd3dba4bed1fda1fd241246f 100644
--- a/third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js
+++ b/third_party/WebKit/Source/devtools/front_end/timeline/TimelineUIUtils.js
@@ -782,7 +782,7 @@ Timeline.TimelineUIUtils = class {
if (eventData['mimeType'])
contentHelper.appendTextRow(Common.UIString('MIME Type'), eventData['mimeType']);
if ('priority' in eventData) {
- var priority = Components.uiLabelForPriority(eventData['priority']);
+ var priority = NetworkConditions.uiLabelForPriority(eventData['priority']);
contentHelper.appendTextRow(Common.UIString('Priority'), priority);
}
if (eventData['encodedDataLength']) {
@@ -1078,7 +1078,7 @@ Timeline.TimelineUIUtils = class {
contentHelper.appendTextRow(Common.UIString('Request Method'), request.requestMethod);
if (typeof request.priority === 'string') {
const priority =
- Components.uiLabelForPriority(/** @type {!Protocol.Network.ResourcePriority} */ (request.priority));
+ NetworkConditions.uiLabelForPriority(/** @type {!Protocol.Network.ResourcePriority} */ (request.priority));
contentHelper.appendTextRow(Common.UIString('Priority'), priority);
}
if (request.mimeType)
@@ -1453,8 +1453,7 @@ Timeline.TimelineUIUtils = class {
'gpu', Common.UIString('GPU'), false, 'hsl(109, 33%, 64%)', 'hsl(109, 33%, 55%)'),
other:
new Timeline.TimelineCategory('other', Common.UIString('Other'), false, 'hsl(0, 0%, 87%)', 'hsl(0, 0%, 79%)'),
- idle: new Timeline.TimelineCategory(
- 'idle', Common.UIString('Idle'), false, 'hsl(0, 0%, 98%)', 'hsl(0, 0%, 98%)')
+ idle: new Timeline.TimelineCategory('idle', Common.UIString('Idle'), false, 'hsl(0, 0%, 98%)', 'hsl(0, 0%, 98%)')
};
return Timeline.TimelineUIUtils._categories;
}

Powered by Google App Engine
This is Rietveld 408576698