|
@ -213,9 +213,7 @@ var SelectionMixin = { |
|
|
this.selectionObj = {}; |
|
|
this.selectionObj = {}; |
|
|
|
|
|
|
|
|
if (doNotTrigger == false) { |
|
|
if (doNotTrigger == false) { |
|
|
this._trigger('select', { |
|
|
|
|
|
nodes: this.getSelection() |
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
this.emit('select', this.getSelection()); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
@ -242,9 +240,7 @@ var SelectionMixin = { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if (doNotTrigger == false) { |
|
|
if (doNotTrigger == false) { |
|
|
this._trigger('select', { |
|
|
|
|
|
nodes: this.getSelection() |
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
this.emit('select', this.getSelection()); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
@ -399,9 +395,7 @@ var SelectionMixin = { |
|
|
this._removeFromSelection(object); |
|
|
this._removeFromSelection(object); |
|
|
} |
|
|
} |
|
|
if (doNotTrigger == false) { |
|
|
if (doNotTrigger == false) { |
|
|
this._trigger('select', { |
|
|
|
|
|
nodes: this.getSelection() |
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
this.emit('select', this.getSelection()); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
@ -512,7 +506,10 @@ var SelectionMixin = { |
|
|
getSelection : function() { |
|
|
getSelection : function() { |
|
|
var nodeIds = this.getSelectedNodes(); |
|
|
var nodeIds = this.getSelectedNodes(); |
|
|
var edgeIds = this.getSelectedEdges(); |
|
|
var edgeIds = this.getSelectedEdges(); |
|
|
return {nodes:nodeIds, edges:edgeIds}; |
|
|
|
|
|
|
|
|
return { |
|
|
|
|
|
nodes: nodeIds, |
|
|
|
|
|
edges: edgeIds |
|
|
|
|
|
}; |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
@ -636,7 +633,7 @@ var SelectionMixin = { |
|
|
======= |
|
|
======= |
|
|
if (changed) { |
|
|
if (changed) { |
|
|
// fire the select event
|
|
|
// fire the select event
|
|
|
this._trigger('select', { |
|
|
|
|
|
|
|
|
this.emit('select', { |
|
|
nodes: this.getSelection() |
|
|
nodes: this.getSelection() |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|