File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -475,7 +475,9 @@ $jit.ST= (function() {
475475 (end code)
476476 */
477477 setRoot : function ( id , method , onComplete ) {
478- var that = this , canvas = this . canvas ;
478+ if ( this . busy ) return ;
479+ this . busy = true ;
480+ var that = this , canvas = this . canvas ;
479481 var rootNode = this . graph . getNode ( this . root ) ;
480482 var clickedNode = this . graph . getNode ( id ) ;
481483 function $setRoot ( ) {
@@ -513,9 +515,11 @@ $jit.ST= (function() {
513515 }
514516 } ) ;
515517 this . compute ( 'end' ) ;
518+ this . busy = true ;
516519 this . fx . animate ( {
517520 modes : [ 'linear' , 'node-property:alpha' ] ,
518521 onComplete : function ( ) {
522+ that . busy = false ;
519523 that . onClick ( id , {
520524 onComplete : function ( ) {
521525 onComplete && onComplete . onComplete ( ) ;
You can’t perform that action at this time.
0 commit comments