Skip to content

Commit

Permalink
Do not call shadowColor = ... when there's no shadow
Browse files Browse the repository at this point in the history
  • Loading branch information
kangax committed Jan 4, 2014
1 parent f335601 commit d7c2076
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/shapes/object.class.js
Original file line number Diff line number Diff line change
Expand Up @@ -995,6 +995,8 @@
* @param {CanvasRenderingContext2D} ctx Context to render on
*/
_removeShadow: function(ctx) {
if (!this.shadow) return;

ctx.shadowColor = '';
ctx.shadowBlur = ctx.shadowOffsetX = ctx.shadowOffsetY = 0;
},
Expand Down

0 comments on commit d7c2076

Please sign in to comment.