Index: tools/turbolizer/turbo-visualizer.js |
diff --git a/tools/turbolizer/turbo-visualizer.js b/tools/turbolizer/turbo-visualizer.js |
index f39b5121656069a6e51059ff60c516e4a0d950d9..6f3f539a39c07c2127cd226ea251f53a338dbfd3 100644 |
--- a/tools/turbolizer/turbo-visualizer.js |
+++ b/tools/turbolizer/turbo-visualizer.js |
@@ -184,6 +184,15 @@ document.onload = (function(d3){ |
selectMenu.add(optionElement, null); |
} |
} |
+ |
+ var eventMenu = document.getElementById('event-selector'); |
+ eventMenu.innerHTML = ''; |
+ for (var event in jsonObj.eventCounts) { |
+ var optionElement = document.createElement("option"); |
+ optionElement.text = event; |
+ eventMenu.add(optionElement, null); |
+ } |
+ disassemblyView.initializePerfProfile(jsonObj.eventCounts); |
disassemblyView.setNodePositionMap(jsonObj.nodePositions); |
disassemblyView.show(disassemblyPhase.data, null); |
@@ -205,6 +214,10 @@ document.onload = (function(d3){ |
displayPhase(jsonObj.phases[selectMenu.selectedIndex]); |
} |
+ eventMenu.onchange = function(item) { |
+ disassemblyView.show(disassemblyView.data, null); |
+ } |
+ |
fitPanesToParents(); |
d3.select("#search-input").attr("value", window.sessionStorage.getItem("lastSearch") || ""); |