diff --git a/src/mbgl/annotation/shape_annotation_impl.cpp b/src/mbgl/annotation/shape_annotation_impl.cpp index 6941c59c3..4b60c667a 100644 --- a/src/mbgl/annotation/shape_annotation_impl.cpp +++ b/src/mbgl/annotation/shape_annotation_impl.cpp @@ -74,6 +74,7 @@ void ShapeAnnotationImpl::updateStyle(Style& style) { layer->id = layerID; layer->source = AnnotationManager::SourceID; layer->sourceLayer = layer->id; + layer->visibility = VisibilityType::Visible; style.addLayer(std::move(layer), sourceLayer->id); } diff --git a/test/fixtures/api/annotation.json b/test/fixtures/api/annotation.json index 75fcfca41..e0792a40b 100644 --- a/test/fixtures/api/annotation.json +++ b/test/fixtures/api/annotation.json @@ -11,6 +11,9 @@ "type": "fill", "source": "fake", "source-layer": "fake", + "layout": { + "visibility": "none" + }, "paint": { "fill-color": "rgba(255,0,0,1)" }