Only set line dash if it is supported

This commit is contained in:
Tom Payne
2013-11-28 17:51:59 +01:00
parent 8d40308d6e
commit f38e5f5f28
2 changed files with 6 additions and 2 deletions

View File

@@ -413,7 +413,9 @@ ol.render.canvas.Immediate.prototype.setFillStrokeStyles_ = function() {
state.currentLineWidth != lineWidth) {
context.strokeStyle = strokeStyle;
context.lineCap = lineCap;
context.setLineDash(lineDash);
if (goog.isDef(context.setLineDash)) {
context.setLineDash(lineDash);
}
context.lineJoin = lineJoin;
context.miterLimit = miterLimit;
context.lineWidth = lineWidth;