Changing relationship line default color

This commit is contained in:
Pablo Luna 2011-01-24 13:18:14 -03:00
parent 03ef9d9770
commit c4858265b1
2 changed files with 8 additions and 2 deletions

View File

@ -65,7 +65,7 @@ mindplot.ConnectionLine.prototype._createLine = function(lineType, defaultStyle)
break;
}
return line;
}
};
mindplot.ConnectionLine.getStrokeColor = function()
{

View File

@ -29,18 +29,24 @@ mindplot.RelationshipLine = function(sourceNode, targetNode, lineType)
this._isInWorkspace = false;
this._controlPointsController = new mindplot.ControlPoint();
var strokeColor = mindplot.ConnectionLine.getStrokeColor.call(this);
var strokeColor = mindplot.RelationshipLine.getStrokeColor();
this._startArrow = new web2d.Arrow();
this._endArrow = new web2d.Arrow();
this._startArrow.setStrokeColor(strokeColor);
this._startArrow.setStrokeWidth(2);
this._endArrow.setStrokeColor(strokeColor);
this._endArrow.setStrokeWidth(2);
this._line2d.setStroke(1, 'solid', strokeColor);
};
objects.extend(mindplot.RelationshipLine, mindplot.ConnectionLine);
mindplot.RelationshipLine.getStrokeColor = function()
{
return '#9b74e6';
};
mindplot.RelationshipLine.prototype.setStroke = function(color, style, opacity)
{
mindplot.RelationshipLine.superClass.setStroke.call(this, color, style, opacity);