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

Side by Side Diff: tools/turbolizer/text-view.js

Issue 2228553004: [turbolizer] Improved display of perf profiling information. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase Created 4 years, 3 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 | « tools/turbolizer/index.html ('k') | tools/turbolizer/turbo-visualizer.css » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 "use strict"; 5 "use strict";
6 6
7 class TextView extends View { 7 class TextView extends View {
8 constructor(id, broker, patterns, allowSpanSelection) { 8 constructor(id, broker, patterns, allowSpanSelection) {
9 super(id, broker); 9 super(id, broker);
10 let view = this; 10 let view = this;
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 113
114 createFragment(text, style) { 114 createFragment(text, style) {
115 let view = this; 115 let view = this;
116 let span = document.createElement("SPAN"); 116 let span = document.createElement("SPAN");
117 span.onmousedown = function(e) { 117 span.onmousedown = function(e) {
118 view.mouseDownSpan(span, e); 118 view.mouseDownSpan(span, e);
119 } 119 }
120 if (style != undefined) { 120 if (style != undefined) {
121 span.classList.add(style); 121 span.classList.add(style);
122 } 122 }
123 span.innerText = text; 123 span.innerHTML = text;
124 return span; 124 return span;
125 } 125 }
126 126
127 appendFragment(li, fragment) { 127 appendFragment(li, fragment) {
128 li.appendChild(fragment); 128 li.appendChild(fragment);
129 } 129 }
130 130
131 processLine(line) { 131 processLine(line) {
132 let view = this; 132 let view = this;
133 let result = []; 133 let result = [];
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 lineLocation(li) { 287 lineLocation(li) {
288 let view = this; 288 let view = this;
289 for (let i = 0; i < li.children.length; ++i) { 289 for (let i = 0; i < li.children.length; ++i) {
290 let fragment = li.children[i]; 290 let fragment = li.children[i];
291 if (fragment.location != undefined && !view.allowSpanSelection) { 291 if (fragment.location != undefined && !view.allowSpanSelection) {
292 return fragment.location; 292 return fragment.location;
293 } 293 }
294 } 294 }
295 } 295 }
296 } 296 }
OLDNEW
« no previous file with comments | « tools/turbolizer/index.html ('k') | tools/turbolizer/turbo-visualizer.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698