Basic tests asserted
This commit is contained in:
@@ -193,11 +193,12 @@ mindplot.layout.RootedTreeSet = new Class({
|
||||
rect.attr('fill', fillColor);
|
||||
|
||||
var rectPosition = {x: rect.attr("x") - canvas.width/2 + rect.attr("width")/2, y:rect.attr("y") - canvas.height/2 + rect.attr("height")/2};
|
||||
var rectSize = {width: rect.attr("width"), height:rect.attr("height")};
|
||||
rect.click(function() {
|
||||
console.log("[id:" + node.getId() + ", order:" + node.getOrder() + ", position:(" + rectPosition.x + "," + rectPosition.y + "), size:" + node.getSize().width + "x" + node.getSize().height + ", sorter:" + node.getSorter() +"]");
|
||||
console.log("[id:" + node.getId() + ", order:" + node.getOrder() + ", position:(" + rectPosition.x + "," + rectPosition.y + "), size:" + rectSize.width + "x" + rectSize.height + ", sorter:" + node.getSorter() +"]");
|
||||
});
|
||||
text.click(function() {
|
||||
console.log("[id:" + node.getId() + ", order:" + node.getOrder() + ", position:(" + rectPosition.x + "," + rectPosition.y + "), size:" + node.getSize().width + "x" + node.getSize().height + ", sorter:" + node.getSorter() +"]");
|
||||
console.log("[id:" + node.getId() + ", order:" + node.getOrder() + ", position:(" + rectPosition.x + "," + rectPosition.y + "), size:" + rectSize.width + "x" + rectSize.height + ", sorter:" + node.getSorter() +"]");
|
||||
});
|
||||
|
||||
for (var i = 0; i < children.length; i++) {
|
||||
|
Reference in New Issue
Block a user