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

Unified Diff: chrome/browser/resources/tracing/timeline.js

Issue 9706010: about:tracing support for TRACE_ASYNC_START/FINISH events. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: try again Created 8 years, 9 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
« no previous file with comments | « chrome/browser/resources/tracing/timeline.css ('k') | chrome/browser/resources/tracing/timeline_model.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/tracing/timeline.js
diff --git a/chrome/browser/resources/tracing/timeline.js b/chrome/browser/resources/tracing/timeline.js
index cfb74ab4331aba591bd8ed796abeb7ff3888dbd4..431ca946f50c1d2f3fb6d568ddad9cad1e567832 100644
--- a/chrome/browser/resources/tracing/timeline.js
+++ b/chrome/browser/resources/tracing/timeline.js
@@ -396,7 +396,7 @@ cr.define('tracing', function() {
threads.forEach(function(thread) {
var track = new tracing.TimelineThreadTrack();
track.heading = thread.userFriendlyName + ':';
- track.tooltip = thread.userFriendlyDetials;
+ track.tooltip = thread.userFriendlyDetails;
track.headingWidth = maxHeadingWidth;
track.viewport = this.viewport_;
track.thread = thread;
@@ -661,16 +661,17 @@ cr.define('tracing', function() {
},
onMouseDown_: function(e) {
- rect = this.tracks_.getClientRects()[0];
+ var canv = this.firstCanvas;
+ var rect = this.tracks_.getClientRects()[0];
var inside = rect &&
e.clientX >= rect.left &&
e.clientX < rect.right &&
e.clientY >= rect.top &&
- e.clientY < rect.bottom;
+ e.clientY < rect.bottom &&
+ e.x >= canv.offsetLeft;
if (!inside)
return;
- var canv = this.firstCanvas;
var pos = {
x: e.clientX - canv.offsetLeft,
y: e.clientY - canv.offsetTop
@@ -743,6 +744,10 @@ cr.define('tracing', function() {
},
onDblClick_: function(e) {
+ var canv = this.firstCanvas;
+ if (e.x < canv.offsetLeft)
+ return;
+
var scale = 4;
if (e.shiftKey)
scale = 1 / scale;
« no previous file with comments | « chrome/browser/resources/tracing/timeline.css ('k') | chrome/browser/resources/tracing/timeline_model.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698