Backport changes for #7668

This commit is contained in:
Andreas Hocevar
2018-01-18 11:12:52 +01:00
parent 61245fb83a
commit 6e9fc2cbad
+2 -2
View File
@@ -992,7 +992,7 @@ ol.render.canvas.Replay.prototype.applyStroke = function(state) {
*/ */
ol.render.canvas.Replay.prototype.createStroke = function(state) { ol.render.canvas.Replay.prototype.createStroke = function(state) {
return [ return [
_ol_render_canvas_Instruction_.SET_STROKE_STYLE, ol.render.canvas.Instruction.SET_STROKE_STYLE,
state.strokeStyle, state.lineWidth * this.pixelRatio, state.lineCap, state.strokeStyle, state.lineWidth * this.pixelRatio, state.lineCap,
state.lineJoin, state.miterLimit, state.lineJoin, state.miterLimit,
this.applyPixelRatio(state.lineDash), state.lineDashOffset * this.pixelRatio this.applyPixelRatio(state.lineDash), state.lineDashOffset * this.pixelRatio
@@ -1005,7 +1005,7 @@ ol.render.canvas.Replay.prototype.createStroke = function(state) {
* @param {function(this:ol.render.canvas.Replay, ol.CanvasFillStrokeState, (ol.geom.Geometry|ol.render.Feature)):Array.<*>} createFill Create fill. * @param {function(this:ol.render.canvas.Replay, ol.CanvasFillStrokeState, (ol.geom.Geometry|ol.render.Feature)):Array.<*>} createFill Create fill.
* @param {ol.geom.Geometry|ol.render.Feature} geometry Geometry. * @param {ol.geom.Geometry|ol.render.Feature} geometry Geometry.
*/ */
_ol_render_canvas_Replay_.prototype.updateFillStyle = function(state, createFill, geometry) { ol.render.canvas.Replay.prototype.updateFillStyle = function(state, createFill, geometry) {
var fillStyle = state.fillStyle; var fillStyle = state.fillStyle;
if (typeof fillStyle !== 'string' || state.currentFillStyle != fillStyle) { if (typeof fillStyle !== 'string' || state.currentFillStyle != fillStyle) {
if (fillStyle !== undefined) { if (fillStyle !== undefined) {