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

Side by Side Diff: LayoutTests/http/tests/inspector/timeline-test.js

Issue 1144963002: Timeline: visually distinguish idle frames (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: review comments Created 5 years, 6 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 | LayoutTests/inspector/tracing/frame-model.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 var initialize_Timeline = function() { 1 var initialize_Timeline = function() {
2 2
3 InspectorTest.preloadPanel("timeline"); 3 InspectorTest.preloadPanel("timeline");
4 WebInspector.TempFile = InspectorTest.TempFileMock; 4 WebInspector.TempFile = InspectorTest.TempFileMock;
5 5
6 // Scrub values when printing out these properties in the record or data field. 6 // Scrub values when printing out these properties in the record or data field.
7 InspectorTest.timelinePropertyFormatters = { 7 InspectorTest.timelinePropertyFormatters = {
8 children: "formatAsTypeName", 8 children: "formatAsTypeName",
9 endTime: "formatAsTypeName", 9 endTime: "formatAsTypeName",
10 requestId: "formatAsTypeName", 10 requestId: "formatAsTypeName",
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 { 325 {
326 this._delegate = delegate; 326 this._delegate = delegate;
327 this._callback = callback; 327 this._callback = callback;
328 this._input = input; 328 this._input = input;
329 this._loadedSize = 0; 329 this._loadedSize = 0;
330 this._fileSize = input.length; 330 this._fileSize = input.length;
331 }; 331 };
332 332
333 InspectorTest.dumpFrame = function(frame) 333 InspectorTest.dumpFrame = function(frame)
334 { 334 {
335 var fieldsToDump = ["cpuTime", "duration", "startTime", "endTime", "id", "ma inThreadFrameId", "timeByCategory", "other", "scripting", "painting", "rendering ", "committedFrom"]; 335 var fieldsToDump = ["cpuTime", "duration", "startTime", "endTime", "id", "ma inThreadFrameId", "timeByCategory", "other", "scripting", "painting", "rendering ", "committedFrom", "idle"];
336 function formatFields(object) 336 function formatFields(object)
337 { 337 {
338 var result = {}; 338 var result = {};
339 for (var key in object) { 339 for (var key in object) {
340 if (fieldsToDump.indexOf(key) < 0) 340 if (fieldsToDump.indexOf(key) < 0)
341 continue; 341 continue;
342 var value = object[key]; 342 var value = object[key];
343 if (typeof value === "number") 343 if (typeof value === "number")
344 value = Number(value.toFixed(7)); 344 value = Number(value.toFixed(7));
345 else if (typeof value === "object" && value) 345 else if (typeof value === "object" && value)
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
404 if (!--count) { 404 if (!--count) {
405 callback(); 405 callback();
406 return; 406 return;
407 } 407 }
408 if (window.testRunner) 408 if (window.testRunner)
409 testRunner.layoutAndPaintAsyncThen(requestAnimationFrame.bind(window , makeFrame)); 409 testRunner.layoutAndPaintAsyncThen(requestAnimationFrame.bind(window , makeFrame));
410 else 410 else
411 window.requestAnimationFrame(makeFrame); 411 window.requestAnimationFrame(makeFrame);
412 } 412 }
413 } 413 }
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/inspector/tracing/frame-model.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698