diff --git a/src/color/Color.js b/src/color/Color.js index bd9ca0df..1ecd6256 100644 --- a/src/color/Color.js +++ b/src/color/Color.js @@ -14,6 +14,7 @@ Color = Base.extend({ else if (this._alpha < 0) this._alpha = 0; else if (alpha > 1) this._alpha = 1; else this._alpha = alpha; + this._cssString = null; }, /** diff --git a/src/color/GrayColor.js b/src/color/GrayColor.js index dd6c5af1..ad54a2a7 100644 --- a/src/color/GrayColor.js +++ b/src/color/GrayColor.js @@ -82,6 +82,7 @@ GrayColor = Color.extend({ return 1 - this._gray; }; fields['set' + key.capitalize()] = function(value) { + this._cssString = null; this._gray = this._gray * (1 - weight) + weight * (1 - value); }; }); diff --git a/src/color/RGBColor.js b/src/color/RGBColor.js index 34f756f6..ff6ace2b 100644 --- a/src/color/RGBColor.js +++ b/src/color/RGBColor.js @@ -156,6 +156,7 @@ RGBColor = Color.extend(new function() { }, setGray: function(gray) { + this._cssString = null; this._red = this._green = this._blue = gray; },