diff --git a/mindplot/pom.xml b/mindplot/pom.xml index 13a7cdff..95403a38 100644 --- a/mindplot/pom.xml +++ b/mindplot/pom.xml @@ -209,7 +209,11 @@ + files="nlayout/AbstractBasicSorter.js"/> + + 0 ? 1 : -1; - var yOffset = ysum + heights[i].height/2; + var yOffset = ysum + heights[i].height / 2; var xOffset = direction * (node.getSize().width + mindplot.nlayout.SymmetricSorter.INTERNODE_HORIZONTAL_PADDING); $assert(!isNaN(xOffset), "xOffset can not be null"); @@ -115,6 +115,15 @@ mindplot.nlayout.SymmetricSorter = new Class({ return result; }, + verify:function(treeSet, node) { + // Check that all is consistent ... + var children = this._getSortedChildren(treeSet, node); + + for (var i = 0; i < children.length; i++) { + $assert(children[i].getOrder() == i, "missing order elements"); + } + }, + toString:function() { return "Symmetric Sorter"; } diff --git a/mindplot/src/main/javascript/nlayout/TestSuite.js b/mindplot/src/test/javascript/static/TestSuite.js similarity index 100% rename from mindplot/src/main/javascript/nlayout/TestSuite.js rename to mindplot/src/test/javascript/static/TestSuite.js diff --git a/mindplot/src/test/javascript/static/layout.html b/mindplot/src/test/javascript/static/layout.html index 67be2ff7..7bd11ec0 100644 --- a/mindplot/src/test/javascript/static/layout.html +++ b/mindplot/src/test/javascript/static/layout.html @@ -19,10 +19,10 @@ - - + + - +