2011-03-03 08:33:41 -05:00
|
|
|
var GradientStop = Base.extend({
|
2011-02-19 16:50:37 -05:00
|
|
|
beans: true,
|
|
|
|
|
|
|
|
// TODO: support midPoint? (initial tests didn't look nice)
|
|
|
|
initialize: function(color, rampPoint) {
|
2011-03-03 12:27:56 -05:00
|
|
|
this._color = Color.read([color]);
|
|
|
|
this._rampPoint = rampPoint !== null ? rampPoint : 0;
|
2011-02-19 16:50:37 -05:00
|
|
|
},
|
|
|
|
|
|
|
|
getRampPoint: function() {
|
|
|
|
return this._rampPoint;
|
|
|
|
},
|
|
|
|
|
|
|
|
setRampPoint: function(rampPoint) {
|
|
|
|
this._rampPoint = rampPoint;
|
|
|
|
},
|
|
|
|
|
|
|
|
getColor: function() {
|
|
|
|
return this._color;
|
|
|
|
},
|
|
|
|
|
|
|
|
setColor: function() {
|
|
|
|
this._color = Color.read(arguments);
|
|
|
|
}
|
2011-03-03 11:32:55 -05:00
|
|
|
});
|