mirror of
https://bitbucket.org/wisemapping/wisemapping-open-source.git
synced 2024-11-27 00:04:55 +01:00
More fixes on connection predict.
This commit is contained in:
parent
04fda82ba0
commit
eb709699b7
@ -75,10 +75,10 @@ mindplot.DragConnector = new Class({
|
|||||||
//
|
//
|
||||||
topics = topics.sort(function (a, b) {
|
topics = topics.sort(function (a, b) {
|
||||||
var aPos = a.getPosition();
|
var aPos = a.getPosition();
|
||||||
var ad = (sourcePosition.x - aPos.x) * Math.sign(aPos.x);
|
var ad = (aPos.x - sourcePosition.x) * Math.sign(aPos.x);
|
||||||
|
|
||||||
var bPos = b.getPosition();
|
var bPos = b.getPosition();
|
||||||
var bd = (sourcePosition.x - bPos.x) * Math.sign(bPos.x);
|
var bd = ( bPos.x - sourcePosition.x) * Math.sign(bPos.x);
|
||||||
|
|
||||||
var av = this._isVerticallyAligned(a.getSize(), a.getPosition(), sourcePosition);
|
var av = this._isVerticallyAligned(a.getSize(), a.getPosition(), sourcePosition);
|
||||||
var bv = this._isVerticallyAligned(b.getSize(), b.getPosition(), sourcePosition);
|
var bv = this._isVerticallyAligned(b.getSize(), b.getPosition(), sourcePosition);
|
||||||
@ -87,11 +87,11 @@ mindplot.DragConnector = new Class({
|
|||||||
|
|
||||||
}.bind(this));
|
}.bind(this));
|
||||||
|
|
||||||
console.log("---- out ----");
|
// console.log("---- out ----");
|
||||||
topics.each(function (e) {
|
// topics.each(function (e) {
|
||||||
console.log(e.getText());
|
// console.log(e.getText());
|
||||||
});
|
// });
|
||||||
console.log("---- out ----");
|
// console.log("---- out ----");
|
||||||
|
|
||||||
|
|
||||||
return topics;
|
return topics;
|
||||||
|
@ -97,7 +97,7 @@ mindplot.layout.SymmetricSorter = new Class({
|
|||||||
var position = {
|
var position = {
|
||||||
x: parentChild.getPosition().x,
|
x: parentChild.getPosition().x,
|
||||||
y: parentChild.getPosition().y + parentChild.getSize().height + mindplot.layout.SymmetricSorter.INTERNODE_VERTICAL_PADDING * 2
|
y: parentChild.getPosition().y + parentChild.getSize().height + mindplot.layout.SymmetricSorter.INTERNODE_VERTICAL_PADDING * 2
|
||||||
}
|
};
|
||||||
return [order, position];
|
return [order, position];
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -111,7 +111,7 @@ mindplot.layout.SymmetricSorter = new Class({
|
|||||||
var position = {
|
var position = {
|
||||||
x: parentChild.getPosition().x,
|
x: parentChild.getPosition().x,
|
||||||
y: parentChild.getPosition().y + (nodeAfter.getPosition().y - parentChild.getPosition().y) / 2
|
y: parentChild.getPosition().y + (nodeAfter.getPosition().y - parentChild.getPosition().y) / 2
|
||||||
}
|
};
|
||||||
|
|
||||||
return [order, position];
|
return [order, position];
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user