Commit 2407e80b authored by techird's avatar techird

selection clear event

parent a69442eb
Subproject commit 7c0498012df602619a38e6b88785a486cd92396d Subproject commit df7b361ae5098710eca0fec1080dce4bc822bf24
...@@ -66,6 +66,12 @@ KM.registerUI( 'hand zoom-in zoom-out', ...@@ -66,6 +66,12 @@ KM.registerUI( 'hand zoom-in zoom-out',
e.stopPropagation(); e.stopPropagation();
} }
} ); } );
me.on('keyup', function(e) {
if(e.keyCode == keymap.Space && me.getSelectedNodes().length == 0) {
$btn.click();
e.preventDefault();
}
});
kity.extendClass( kity.Paper, kity.Draggable ); kity.extendClass( kity.Paper, kity.Draggable );
break; break;
case 'zoom-in': case 'zoom-in':
......
...@@ -26,6 +26,7 @@ kity.extendClass( Minder, function () { ...@@ -26,6 +26,7 @@ kity.extendClass( Minder, function () {
unhighlightNode( me, n ); unhighlightNode( me, n );
} ); } );
this._selectedNodes = []; this._selectedNodes = [];
return this.fire( 'selectionclear' );
}, },
removeSelectedNodes: function ( nodes ) { removeSelectedNodes: function ( nodes ) {
var me = this; var me = this;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment