diff --git a/HISTORY.md b/HISTORY.md index a52cdf92..6d825b1c 100644 --- a/HISTORY.md +++ b/HISTORY.md @@ -8,6 +8,7 @@ http://visjs.org - Fixed another clustering bug, phantom edges should be gone now. - Fixed disabling hierarchical layout. +- Fixed delete button when using multiple selected items in manipulation system. ## 2015-07-17, version 4.5.0 diff --git a/dist/vis.js b/dist/vis.js index 7720713e..e835518c 100644 --- a/dist/vis.js +++ b/dist/vis.js @@ -5,7 +5,7 @@ * A dynamic, browser-based visualization library. * * @version 4.5.1--snapshot - * @date 2015-07-17 + * @date 2015-07-20 * * @license * Copyright (C) 2011-2014 Almende B.V, http://almende.com @@ -38636,7 +38636,7 @@ return /******/ (function(modules) { // webpackBootstrap // remove buttons if (selectedTotalCount !== 0) { - if (selectedNodeCount === 1 && this.options.deleteNode !== false) { + if (selectedNodeCount > 0 && this.options.deleteNode !== false) { if (needSeperator === true) { this._createSeperator(4); } diff --git a/lib/network/modules/ManipulationSystem.js b/lib/network/modules/ManipulationSystem.js index f6a6a247..1d81d1f5 100644 --- a/lib/network/modules/ManipulationSystem.js +++ b/lib/network/modules/ManipulationSystem.js @@ -192,7 +192,7 @@ class ManipulationSystem { // remove buttons if (selectedTotalCount !== 0) { - if (selectedNodeCount === 1 && this.options.deleteNode !== false) { + if (selectedNodeCount > 0 && this.options.deleteNode !== false) { if (needSeperator === true) { this._createSeperator(4); } diff --git a/test/networkTest.html b/test/networkTest.html index 7a948c12..28ba4689 100644 --- a/test/networkTest.html +++ b/test/networkTest.html @@ -1,148 +1,116 @@ - Network | Hierarchical layout - + Network | Clustering + + - + +
- - - - -

Hierarchical Layout - Scale-Free-Network

- -
- This example shows the randomly generated scale-free-network set of nodes and connected edges from example 2. - In this example, hierarchical layout has been enabled and the vertical levels are determined automatically. -
-
- -
- - - -
-

- - - - - -

- - -
- -
-

- + \ No newline at end of file