Clean up code references to GradientColor.

This commit is contained in:
Jürg Lehni 2013-04-09 08:36:17 -07:00
parent bf21e32082
commit da7b32a18e
3 changed files with 4 additions and 4 deletions

View file

@ -47,7 +47,7 @@ var GradientStop = this.GradientStop = Base.extend(/** @lends GradientStop# */{
// TODO: Do we really need to also clone the color here?
/**
* @return {GradientColor} a copy of the gradient-stop
* @return {GradientStop} a copy of the gradient-stop
*/
clone: function() {
return new GradientStop(this._color.clone(), this._rampPoint);

View file

@ -153,10 +153,10 @@ new function() {
origin = getPoint(node, 'x1', 'y1');
destination = getPoint(node, 'x2', 'y2');
}
// We don't return the GradientColor, since we only need a reference to
// it in definitions, which is created in applyAttributes()
applyAttributes(
new Color(gradient, origin, destination, highlight), node);
// We don't return the gradient, since we only need a reference to it in
// definitions, which is created in applyAttributes()
return null;
}

View file

@ -51,7 +51,7 @@ test('Path#clone()', function() {
cloneAndCompare(path);
});
test('Path#clone() with GradientColor', function() {
test('Path#clone() with gradient Color', function() {
var colors = ['red', 'green', 'black'];
var gradient = new Gradient(colors, true);
var color = new Color(gradient, [0, 0], [20, 20], [10, 10]);