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

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

Issue 726653003: DevTools: add Paint Profiler link to layer & event details views (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 1 month 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/TimelinePanel.js
diff --git a/Source/devtools/front_end/timeline/TimelinePanel.js b/Source/devtools/front_end/timeline/TimelinePanel.js
index 36b44ad095d50ea58f7c884fe6bf67c0eb6e34d6..61331ed2dba96abbfb0585793da2b8c3b206f414 100644
--- a/Source/devtools/front_end/timeline/TimelinePanel.js
+++ b/Source/devtools/front_end/timeline/TimelinePanel.js
@@ -985,7 +985,8 @@ WebInspector.TimelinePanel.prototype = {
_appendDetailsTabsForTraceEventAndShowDetails: function(event, content)
{
this.showInDetails(content);
- this._showEventInPaintProfiler(event);
+ if (event.name === WebInspector.TimelineModel.RecordType.Paint)
+ this._showEventInPaintProfiler(event);
},
/**
@@ -1000,7 +1001,6 @@ WebInspector.TimelinePanel.prototype = {
var paintProfilerView = this._paintProfilerView();
if (!this._detailsView.hasTab(WebInspector.TimelinePanel.DetailsTab.PaintProfiler))
this._detailsView.appendTab(WebInspector.TimelinePanel.DetailsTab.PaintProfiler, WebInspector.UIString("Paint Profiler"), paintProfilerView, undefined, undefined, isCloseable);
- this._detailsView.selectTab(WebInspector.TimelinePanel.DetailsTab.PaintProfiler, true);
event.picture.requestObject(onGotObject);
function onGotObject(result)
{
@@ -1112,6 +1112,7 @@ WebInspector.TimelinePanel.prototype = {
{
var event = record.traceEvent();
this._showEventInPaintProfiler(event, true);
+ this._detailsView.selectTab(WebInspector.TimelinePanel.DetailsTab.PaintProfiler, true);
},
/**
@@ -1446,13 +1447,13 @@ WebInspector.TimelineTextFilter.prototype = {
WebInspector.TimelinePanel.show = function()
{
- WebInspector.inspectorView.setCurrentPanel(WebInspector.TimelinePanel._instance());
+ WebInspector.inspectorView.setCurrentPanel(WebInspector.TimelinePanel.instance());
}
/**
* @return {!WebInspector.TimelinePanel}
*/
-WebInspector.TimelinePanel._instance = function()
+WebInspector.TimelinePanel.instance = function()
{
if (!WebInspector.TimelinePanel._instanceObject)
WebInspector.TimelinePanel._instanceObject = new WebInspector.TimelinePanel();
@@ -1473,6 +1474,6 @@ WebInspector.TimelinePanelFactory.prototype = {
*/
createPanel: function()
{
- return WebInspector.TimelinePanel._instance();
+ return WebInspector.TimelinePanel.instance();
}
}
« no previous file with comments | « Source/devtools/front_end/timeline/TimelineLayersView.js ('k') | Source/devtools/front_end/timeline/TimelineUIUtils.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698