Browse Source

- Fixed bug where dragging a node that is not a control node during edit edge mode would throw an error.

webworkersNetwork
Alex de Mulder 9 years ago
parent
commit
59a5fe8053
3 changed files with 11 additions and 0 deletions
  1. +1
    -0
      HISTORY.md
  2. +5
    -0
      dist/vis.js
  3. +5
    -0
      lib/network/modules/ManipulationSystem.js

+ 1
- 0
HISTORY.md View File

@ -7,6 +7,7 @@ http://visjs.org
- Fixed bug where an edge that was not connected would crash the layout algorithms.
- Fixed bug where a box shape could not be drawn outside of the viewable area.
- Fixed bug where dragging a node that is not a control node during edit edge mode would throw an error.
## 2015-09-14, version 4.8.2

+ 5
- 0
dist/vis.js View File

@ -40709,6 +40709,11 @@ return /******/ (function(modules) { // webpackBootstrap
var pointerObj = this.selectionHandler._pointerToPositionObject(pointer);
var edge = this.body.edges[this.edgeBeingEditedId];
// if the node that was dragged is not a control node, return
if (this.selectedControlNode === undefined) {
return;
}
var overlappingNodeIds = this.selectionHandler._getAllNodesOverlappingWith(pointerObj);
var node = undefined;
for (var i = overlappingNodeIds.length - 1; i >= 0; i--) {

+ 5
- 0
lib/network/modules/ManipulationSystem.js View File

@ -893,6 +893,11 @@ class ManipulationSystem {
let pointerObj = this.selectionHandler._pointerToPositionObject(pointer);
let edge = this.body.edges[this.edgeBeingEditedId];
// if the node that was dragged is not a control node, return
if (this.selectedControlNode === undefined) {
return;
}
let overlappingNodeIds = this.selectionHandler._getAllNodesOverlappingWith(pointerObj);
let node = undefined;
for (let i = overlappingNodeIds.length-1; i >= 0; i--) {

Loading…
Cancel
Save