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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/components/NetworkConditionsSelector.js

Issue 1875843003: [DevTools] Fix bad unicode symbols in network conditions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2661
Patch Set: Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 * @constructor 6 * @constructor
7 * @param {function(!Array<!WebInspector.NetworkConditionsGroup>):!Array<?WebIns pector.NetworkManager.Conditions>} populateCallback 7 * @param {function(!Array<!WebInspector.NetworkConditionsGroup>):!Array<?WebIns pector.NetworkManager.Conditions>} populateCallback
8 * @param {function(number)} selectCallback 8 * @param {function(number)} selectCallback
9 */ 9 */
10 WebInspector.NetworkConditionsSelector = function(populateCallback, selectCallba ck) 10 WebInspector.NetworkConditionsSelector = function(populateCallback, selectCallba ck)
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 options = []; 129 options = [];
130 for (var i = 0; i < groups.length; ++i) { 130 for (var i = 0; i < groups.length; ++i) {
131 var group = groups[i]; 131 var group = groups[i];
132 var groupElement = selectElement.createChild("optgroup"); 132 var groupElement = selectElement.createChild("optgroup");
133 groupElement.label = group.title; 133 groupElement.label = group.title;
134 if (!i) { 134 if (!i) {
135 groupElement.appendChild(new Option(WebInspector.UIString("Add\u 2026"), WebInspector.UIString("Add\u2026"))); 135 groupElement.appendChild(new Option(WebInspector.UIString("Add\u 2026"), WebInspector.UIString("Add\u2026")));
136 options.push(null); 136 options.push(null);
137 } 137 }
138 for (var conditions of group.items) { 138 for (var conditions of group.items) {
139 var title = WebInspector.NetworkConditionsSelector._conditionsTi tle(conditions); 139 var title = WebInspector.NetworkConditionsSelector._conditionsTi tle(conditions, true);
140 var option = new Option(title.text, title.text); 140 var option = new Option(title.text, title.text);
141 option.title = title.title; 141 option.title = title.title;
142 groupElement.appendChild(option); 142 groupElement.appendChild(option);
143 options.push(conditions); 143 options.push(conditions);
144 } 144 }
145 } 145 }
146 return options; 146 return options;
147 } 147 }
148 148
149 function optionSelected() 149 function optionSelected()
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
420 */ 420 */
421 function latencyValidator(item, index, input) 421 function latencyValidator(item, index, input)
422 { 422 {
423 var value = input.value.trim(); 423 var value = input.value.trim();
424 return !value || (/^[\d]+$/.test(value) && value >= 0 && value <= 10 00000); 424 return !value || (/^[\d]+$/.test(value) && value >= 0 && value <= 10 00000);
425 } 425 }
426 }, 426 },
427 427
428 __proto__: WebInspector.VBox.prototype 428 __proto__: WebInspector.VBox.prototype
429 } 429 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698