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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/perf_ui/FlameChart.js

Issue 2654253004: DevTools: fix flame chart on profiler pane (Closed)
Patch Set: Created 3 years, 11 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 | « third_party/WebKit/LayoutTests/inspector/components/flame-chart-expected.txt ('k') | 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 /** 1 /**
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 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 1008 matching lines...) Expand 10 before | Expand all | Expand 10 after
1019 var groups = this._rawTimelineData.groups || []; 1019 var groups = this._rawTimelineData.groups || [];
1020 this._visibleLevelOffsets = new Uint32Array(levelCount + 1); 1020 this._visibleLevelOffsets = new Uint32Array(levelCount + 1);
1021 this._visibleLevels = new Uint16Array(levelCount); 1021 this._visibleLevels = new Uint16Array(levelCount);
1022 this._groupOffsets = new Uint32Array(groups.length + 1); 1022 this._groupOffsets = new Uint32Array(groups.length + 1);
1023 1023
1024 var groupIndex = -1; 1024 var groupIndex = -1;
1025 var currentOffset = this._rulerEnabled ? PerfUI.FlameChart.HeaderHeight : 2; 1025 var currentOffset = this._rulerEnabled ? PerfUI.FlameChart.HeaderHeight : 2;
1026 var visible = true; 1026 var visible = true;
1027 /** @type !Array<{nestingLevel: number, visible: boolean}> */ 1027 /** @type !Array<{nestingLevel: number, visible: boolean}> */
1028 var groupStack = [{nestingLevel: -1, visible: true}]; 1028 var groupStack = [{nestingLevel: -1, visible: true}];
1029 var lastGroupLevel = Math.max(levelCount, groups.peekLast().startLevel + 1); 1029 var lastGroupLevel = Math.max(levelCount, groups.length ? groups.peekLast(). startLevel + 1 : 0);
1030 for (var level = 0; level < lastGroupLevel; ++level) { 1030 for (var level = 0; level < lastGroupLevel; ++level) {
1031 while (groupIndex < groups.length - 1 && level === groups[groupIndex + 1]. startLevel) { 1031 while (groupIndex < groups.length - 1 && level === groups[groupIndex + 1]. startLevel) {
1032 ++groupIndex; 1032 ++groupIndex;
1033 var style = groups[groupIndex].style; 1033 var style = groups[groupIndex].style;
1034 var nextLevel = true; 1034 var nextLevel = true;
1035 while (groupStack.peekLast().nestingLevel >= style.nestingLevel) { 1035 while (groupStack.peekLast().nestingLevel >= style.nestingLevel) {
1036 groupStack.pop(); 1036 groupStack.pop();
1037 nextLevel = false; 1037 nextLevel = false;
1038 } 1038 }
1039 var thisGroupIsVisible = 1039 var thisGroupIsVisible =
(...skipping 489 matching lines...) Expand 10 before | Expand all | Expand 10 after
1529 } 1529 }
1530 1530
1531 /** 1531 /**
1532 * @override 1532 * @override
1533 * @return {number} 1533 * @return {number}
1534 */ 1534 */
1535 boundarySpan() { 1535 boundarySpan() {
1536 return this._maximumBoundaries - this._minimumBoundaries; 1536 return this._maximumBoundaries - this._minimumBoundaries;
1537 } 1537 }
1538 }; 1538 };
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/inspector/components/flame-chart-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698