diff --git a/HISTORY.md b/HISTORY.md index 3a4c3a23..b2f7a339 100644 --- a/HISTORY.md +++ b/HISTORY.md @@ -12,6 +12,8 @@ http://visjs.org - Improved layout of box-items inside groups. - Fixed option `autoResize` forcing a repaint of the Timeline with every check rather than when the Timeline is actually resized. +- Fixed `select` event fired repeatedly when clicking an empty place on the + Timeline, deselecting selected items). - Minor bug fixes. - More examples added. diff --git a/src/timeline/component/ItemSet.js b/src/timeline/component/ItemSet.js index 77233381..42690650 100644 --- a/src/timeline/component/ItemSet.js +++ b/src/timeline/component/ItemSet.js @@ -705,8 +705,8 @@ ItemSet.prototype._onDragEnd = function (event) { if ('start' in props) props.item.data.start = props.start; if ('end' in props) props.item.data.end = props.end; - this.stackDirty = true; // force re-stacking of all items next repaint - this.emit('change'); + me.stackDirty = true; // force re-stacking of all items next repaint + me.emit('change'); } }); }