From 353e0a8f78ab751d4df62f6780755938318f7529 Mon Sep 17 00:00:00 2001 From: BigEd Date: Fri, 5 Nov 2010 21:21:06 +0000 Subject: [PATCH] highlight a list of nodes by name or number --- expert.html | 11 +++++++---- expertWires.js | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+), 4 deletions(-) diff --git a/expert.html b/expert.html index 816cf26..58d1092 100644 --- a/expert.html +++ b/expert.html @@ -85,14 +85,17 @@ $().ready(function(){ (metal) (protection) -
- - + + + + Animate during simulation: -   +
+
+ Link to this location
diff --git a/expertWires.js b/expertWires.js index 1a9ae80..db7f2e9 100644 --- a/expertWires.js +++ b/expertWires.js @@ -279,6 +279,39 @@ function recenter(){ document.getElementById('linkHere').href=location.pathname+"?"+whereAmIAsQuery(); } +var highlightThese; + +// flash some set of nodes according to user input +function hiliteNodeList(){ + var tmplist = document.getElementById('HighlightThese').value.split(/[\s,]+/); + if(tmplist.length==0){ + // request to highlight nothing, so switch off any signal highlighting + hiliteNode(-1); + return; + } + highlightThese = []; + for(var i=0;i