Chromium Code Reviews| Index: chrome/browser/resources/gpu_internals/timeline_track.js |
| diff --git a/chrome/browser/resources/gpu_internals/timeline_track.js b/chrome/browser/resources/gpu_internals/timeline_track.js |
| index 493be171be1faba51d569aa5eff4639a2169d8cd..d1a2ce0c428daf1e39ae30117964ac2379d247c5 100644 |
| --- a/chrome/browser/resources/gpu_internals/timeline_track.js |
| +++ b/chrome/browser/resources/gpu_internals/timeline_track.js |
| @@ -132,8 +132,12 @@ cr.define('gpu', function() { |
| addTrack(this, this.thread_.subRows[srI]); |
| } |
| if (this.tracks_.length > 0) { |
| + var tname = this.thread_.name || this.thread_.tid; |
| this.tracks_[0].heading = this.thread_.parent.pid + ': ' + |
| - this.thread_.tid + ': '; |
| + tname + ':'; |
| + this.tracks_[0].title = 'pid: ' + this.thread_.parent.pid + |
| + ', tid: ' + this.thread_.tid + |
| + this.thread_.name ? ', name; ' + this.thread_.name : ''; |
|
jbates
2011/07/26 18:28:11
semicolon after name -> colon
|
| } |
| } |
| }, |
| @@ -194,9 +198,9 @@ cr.define('gpu', function() { |
| this.className = 'timeline-slice-track'; |
| this.slices_ = null; |
| - this.titleDiv_ = document.createElement('div'); |
| - this.titleDiv_.className = 'timeline-slice-track-title'; |
| - this.appendChild(this.titleDiv_); |
| + this.headingSpan_ = document.createElement('span'); |
| + this.headingSpan_.className = 'timeline-slice-track-title'; |
| + this.appendChild(this.headingSpan_); |
| this.canvasContainer_ = document.createElement('div'); |
| this.canvasContainer_.className = 'timeline-slice-track-canvas-container'; |
| @@ -209,7 +213,11 @@ cr.define('gpu', function() { |
| }, |
| set heading(text) { |
| - this.titleDiv_.textContent = text; |
| + this.headingSpan_.textContent = text; |
| + }, |
| + |
| + set title(text) { |
| + this.headingSpan_.textContent = text; |
| }, |
| set slices(slices) { |
| @@ -309,7 +317,7 @@ cr.define('gpu', function() { |
| if (slice.duration > quickDiscardThresshold) { |
| var title = slice.title; |
| if (slice.didNotFinish) { |
| - title += " (Did Not Finish)"; |
| + title += ' (Did Not Finish)'; |
| } |
| var labelWidth = quickMeasureText(ctx, title) + 2; |
| var labelWidthWorld = pixWidth * labelWidth; |