Only replay replay group if it is not empty

This commit is contained in:
Tom Payne
2014-02-13 14:47:47 +01:00
parent 5b8e85afbd
commit a178712f6b

View File

@@ -69,7 +69,7 @@ ol.renderer.canvas.VectorLayer.prototype.composeFrame =
this.dispatchPreComposeEvent(context, frameState, transform); this.dispatchPreComposeEvent(context, frameState, transform);
var replayGroup = this.replayGroup_; var replayGroup = this.replayGroup_;
if (!goog.isNull(replayGroup)) { if (!goog.isNull(replayGroup) && !replayGroup.isEmpty()) {
var renderGeometryFunction = this.getRenderGeometryFunction_(); var renderGeometryFunction = this.getRenderGeometryFunction_();
goog.asserts.assert(goog.isFunction(renderGeometryFunction)); goog.asserts.assert(goog.isFunction(renderGeometryFunction));
context.globalAlpha = layerState.opacity; context.globalAlpha = layerState.opacity;