Add mutligraph support for floid algorithm

This commit is contained in:
Unick Soft 2020-02-23 11:28:56 +02:00
parent a5e44e1858
commit 1e6dbc279f

View File

@ -207,12 +207,16 @@ FloidAlgorithm.prototype.restore = function()
for (var i = 0; i < this.egdesCopy.length; i ++)
{
var edge = this.graph.AddNewEdgeSafe(this.egdesCopy[i].vertex1,
var edgeIndex = this.graph.AddNewEdgeSafe(this.egdesCopy[i].vertex1,
this.egdesCopy[i].vertex2,
this.egdesCopy[i].isDirect,
this.egdesCopy[i].weight,
this.isGraphMulti);
var edge = this.graph.edges[edgeIndex];
edge.model.type = this.egdesCopy[i].model.type;
edge.model.curvedValue = this.egdesCopy[i].model.curvedValue;
//edge.model = this.egdesCopy[i].model;
}
}
@ -226,7 +230,7 @@ FloidAlgorithm.prototype.updateMessage = function(save)
// Algorithm support multi graph
FloidAlgorithm.prototype.IsSupportMultiGraph = function ()
{
return false;
return true;
}
// Factory for connected components.