mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-01 02:38:43 -05:00
parent
fd1a517e84
commit
c0abbe1459
1 changed files with 4 additions and 1 deletions
|
@ -751,13 +751,16 @@ var Raster = Item.extend(/** @lends Raster# */{
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
_draw: function(ctx) {
|
_draw: function(ctx, param, viewMatrix) {
|
||||||
var element = this.getElement();
|
var element = this.getElement();
|
||||||
if (element) {
|
if (element) {
|
||||||
// Handle opacity for Rasters separately from the rest, since
|
// Handle opacity for Rasters separately from the rest, since
|
||||||
// Rasters never draw a stroke. See Item#draw().
|
// Rasters never draw a stroke. See Item#draw().
|
||||||
ctx.globalAlpha = this._opacity;
|
ctx.globalAlpha = this._opacity;
|
||||||
|
|
||||||
|
// Call _setStyles() to make sure shadow is drawn (#1437).
|
||||||
|
this._setStyles(ctx, param, viewMatrix);
|
||||||
|
|
||||||
// Set context smoothing value according to raster property.
|
// Set context smoothing value according to raster property.
|
||||||
// There's no need to restore original value after drawing due to
|
// There's no need to restore original value after drawing due to
|
||||||
// the call to ctx.restore() in Item#draw() after this method call.
|
// the call to ctx.restore() in Item#draw() after this method call.
|
||||||
|
|
Loading…
Reference in a new issue