summaryrefslogtreecommitdiff
path: root/platform/node
diff options
context:
space:
mode:
authorBruno de Oliveira Abinader <bruno@mapbox.com>2019-03-21 18:36:43 +0200
committerBruno de Oliveira Abinader <bruno@mapbox.com>2019-03-22 18:54:48 +0200
commit03db58cdc1f1f31034863020f205f5c5696bfa8b (patch)
treee4201a14948d3772fbd4f8bcff6f7d38e2dfd27d /platform/node
parent2de2b0b068520a55170d23c86f349232b3e28ae7 (diff)
downloadqtlocation-mapboxgl-03db58cdc1f1f31034863020f205f5c5696bfa8b.tar.gz
[core] Replace shared_ptr with unique_ptr in {Map,Resource}Options
Diffstat (limited to 'platform/node')
-rw-r--r--platform/node/src/node_map.cpp11
1 files changed, 3 insertions, 8 deletions
diff --git a/platform/node/src/node_map.cpp b/platform/node/src/node_map.cpp
index 0b27d378a7..7ad9c362bf 100644
--- a/platform/node/src/node_map.cpp
+++ b/platform/node/src/node_map.cpp
@@ -631,14 +631,9 @@ void NodeMap::cancel() {
});
frontend = std::make_unique<mbgl::HeadlessFrontend>(mbgl::Size{ 256, 256 }, pixelRatio, threadpool);
- auto mapOptions = mbgl::MapOptions()
- .withMapMode(mode)
- .withCrossSourceCollisions(crossSourceCollisions);
-
- auto resourceOptions = mbgl::ResourceOptions().withPlatformContext(reinterpret_cast<void*>(this));
-
- map = std::make_unique<mbgl::Map>(*frontend, mapObserver, frontend->getSize(), pixelRatio,
- threadpool, mapOptions, resourceOptions);
+ map = std::make_unique<mbgl::Map>(*frontend, mapObserver, frontend->getSize(), pixelRatio, threadpool,
+ mbgl::MapOptions().withMapMode(mode).withCrossSourceCollisions(crossSourceCollisions),
+ mbgl::ResourceOptions().withPlatformContext(reinterpret_cast<void*>(this)));
// FIXME: Reload the style after recreating the map. We need to find
// a better way of canceling an ongoing rendering on the core level