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

Unified Diff: third_party/WebKit/Source/devtools/front_end/ui_lazy/FlameChart.js

Issue 1463393003: DevTools: Make item info follow the mouse on the flame chart. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: addressing comments + coloring Created 5 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: third_party/WebKit/Source/devtools/front_end/ui_lazy/FlameChart.js
diff --git a/third_party/WebKit/Source/devtools/front_end/ui_lazy/FlameChart.js b/third_party/WebKit/Source/devtools/front_end/ui_lazy/FlameChart.js
index 3163b9a199aff762507a2a17fdb87769fc7122ed..948a5742e7bdf7c44337166771bd0a3f70a660c7 100644
--- a/third_party/WebKit/Source/devtools/front_end/ui_lazy/FlameChart.js
+++ b/third_party/WebKit/Source/devtools/front_end/ui_lazy/FlameChart.js
@@ -691,6 +691,8 @@ WebInspector.FlameChart.prototype = {
var inDividersBar = event.offsetY < WebInspector.FlameChart.DividersBarHeight;
this._highlightedMarkerIndex = inDividersBar ? this._markerIndexAtPosition(event.offsetX) : -1;
this._updateMarkerHighlight();
+ this._entryInfo.style.left = event.offsetX + "px";
+ this._entryInfo.style.top = event.offsetY + "px";
this._highlightEntry(this._coordinatesToEntryIndex(event.offsetX, event.offsetY));
},
@@ -1395,7 +1397,10 @@ WebInspector.FlameChart.prototype = {
for (var entry of entryInfo) {
var row = infoTable.createChild("tr");
row.createChild("td", "title").textContent = entry.title;
- row.createChild("td").textContent = typeof entry.value === "string" ? entry.value : entry.value.textContent;
+ if (typeof entry.value === "string")
+ row.createChild("td").textContent = entry.value;
+ else
+ row.createChild("td").appendChild(entry.value);
}
return infoTable;
},

Powered by Google App Engine
This is Rietveld 408576698