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

Unified Diff: Source/devtools/front_end/timeline/TimelineFrameModel.js

Issue 1174223006: DevTools: Adjust bad frames color on timeline flamechart. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: Source/devtools/front_end/timeline/TimelineFrameModel.js
diff --git a/Source/devtools/front_end/timeline/TimelineFrameModel.js b/Source/devtools/front_end/timeline/TimelineFrameModel.js
index c23f1b1ed31c7feb31c7317283d5b68d9efeaea5..2ee01fef79a80d80cd16351af33bebff78e7953d 100644
--- a/Source/devtools/front_end/timeline/TimelineFrameModel.js
+++ b/Source/devtools/front_end/timeline/TimelineFrameModel.js
@@ -572,6 +572,15 @@ WebInspector.TimelineFrame = function(startTime, startTimeOffset)
WebInspector.TimelineFrame.prototype = {
/**
+ * @return {boolean}
+ */
+ hasWarnings: function()
+ {
+ var /** @const */ longFrameDurationThresholdMs = 18;
+ return !this.idle && this.duration > longFrameDurationThresholdMs;
+ },
+
+ /**
* @param {number} endTime
*/
_setEndTime: function(endTime)

Powered by Google App Engine
This is Rietveld 408576698