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

Unified Diff: tools/turbolizer/graph-view.js

Issue 2061713002: [turbolizer]: Fix bugs (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 6 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 | « no previous file | tools/turbolizer/index.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/turbolizer/graph-view.js
diff --git a/tools/turbolizer/graph-view.js b/tools/turbolizer/graph-view.js
index efddc90a7d8b771f4134aa8ebf1fca8edf952d52..39eb775ba675aa5fc7515fa17dec14a1359fe0fa 100644
--- a/tools/turbolizer/graph-view.js
+++ b/tools/turbolizer/graph-view.js
@@ -571,6 +571,7 @@ class GraphView extends View {
}
var allowRepetition = true;
+ var eventHandled = true; // unless the below switch defaults
switch(d3.event.keyCode) {
case 49:
case 50:
@@ -616,6 +617,12 @@ class GraphView extends View {
selectNodesThroughEdges(d3.event.keyCode == 38, undefined, true);
break;
}
+ default:
+ eventHandled = false;
+ break;
+ }
+ if (eventHandled) {
+ d3.event.preventDefault();
}
if (!allowRepetition) {
state.lastKeyDown = d3.event.keyCode;
« no previous file with comments | « no previous file | tools/turbolizer/index.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698