@@ -57,6 +57,11 @@ export const ThreadMap: React.FC<ThreadMapPanelProps> = ({ options, data, width,
5757 }
5858 let minValLength = ( minVal . toString ( ) . length ) * 11
5959
60+ //Call Filter
61+ if ( options . UseFileSystemFinder ) {
62+ FileSystemFinder ( ) ;
63+ }
64+
6065 drawThreadMap ( )
6166
6267 //functions
@@ -86,7 +91,7 @@ export const ThreadMap: React.FC<ThreadMapPanelProps> = ({ options, data, width,
8691 }
8792 return ( Colour )
8893 }
89-
94+
9095 function ColourAssignment ( Colour : any , lDatalength : any ) {
9196 let ctrTpP = 0
9297 var ThreadHeatValue : any [ ] = [ ]
@@ -247,12 +252,22 @@ export const ThreadMap: React.FC<ThreadMapPanelProps> = ({ options, data, width,
247252 cy : 140 ,
248253 r : 6 ,
249254 colour : Colour ,
250- class : "Thread"
255+ class : "Thread" ,
256+ stroke : ''
251257 }
252258 )
253259 }
254260
255- function drawThreadMap ( ) {
261+ function FileSystemFinder ( ) {
262+ for ( let i = 0 ; i < MapData . length ; i ++ ) {
263+ if ( MapData [ i ] . affiliated . includes ( options . FileSystemFinder ) ) {
264+ MapData [ i ] . stroke = 'pink' ;
265+ }
266+ }
267+ console . log ( MapData )
268+ }
269+
270+ function drawThreadMap ( ) {
256271 const svgTM = d3 . select ( '#ThreadMapMain' ) ;
257272 const backgroundTooltip = d3
258273 . select ( '#ThreadMapMain' )
@@ -315,6 +330,11 @@ function drawThreadMap() {
315330 . style ( 'fill' , function ( d : any ) {
316331 return d . colour ;
317332 } )
333+ . attr ( 'stroke' , function ( d : any ) {
334+ return d . stroke ;
335+ } )
336+ . attr ( 'stroke-width' , 2 )
337+
318338 . on ( 'mouseover' , function ( d ) {
319339 d3 . select ( this ) . transition ( ) . duration ( 50 ) . attr ( 'opacity' , '.85' ) ;
320340 backgroundTooltip . transition ( ) . duration ( 50 ) . style ( 'opacity' , 1 ) ;
@@ -414,11 +434,24 @@ function drawThreadMap() {
414434 ProcessIDForceGraph
415435 . attr ( 'ProcessID' , d . name )
416436 //Remove old highlight
417- d3 . selectAll ( 'circle' ) . attr ( 'stroke' , null ) ;
437+ d3 . selectAll ( 'circle' )
438+ . filter ( function ( ) { return d3 . select ( this ) . attr ( 'r' ) === '8' ; } )
439+ . attr ( 'stroke' , null ) ;
418440 //Add Highliting
419441 d3 . select ( this ) . attr ( 'stroke' , 'blue' ) . attr ( 'stroke-width' , 2 ) ;
420442 }
421443 } ) ;
444+ //Highlight Threads with filtered Filenames
445+ //Remove old highlight
446+ d3 . selectAll ( 'circle' )
447+ . filter ( function ( ) { return d3 . select ( this ) . attr ( 'r' ) === '6' ; } )
448+ . attr ( 'stroke' , null ) ;
449+ d3 . selectAll ( 'circle' )
450+ . filter ( function ( ) { return d3 . select ( this ) . attr ( 'r' ) === '6' ; } )
451+ . attr ( 'stroke' , function ( d : any ) {
452+ return d . stroke ;
453+ } )
454+ . attr ( 'stroke-width' , 2 )
422455 //Style MinMax Display
423456 //remove old min max
424457 d3 . select ( '#minValueText' ) . remove ( ) ;
0 commit comments