summaryrefslogtreecommitdiff
path: root/src/mbgl/map/map.cpp
diff options
context:
space:
mode:
authorBruno de Oliveira Abinader <bruno@mapbox.com>2017-08-11 14:38:19 +0300
committerBruno de Oliveira Abinader <bruno@mapbox.com>2017-08-11 22:04:52 +0300
commit6179e0f9c05d178b2475e54a49568b57d66b68ae (patch)
treec79aa5e8292971063720b67af5ff517d4e25a003 /src/mbgl/map/map.cpp
parent98f7d4db5761f527fb9677d5ec575c2f064e1847 (diff)
downloadqtlocation-mapboxgl-6179e0f9c05d178b2475e54a49568b57d66b68ae.tar.gz
[core] Added Style::getDefaultCamera()
Diffstat (limited to 'src/mbgl/map/map.cpp')
-rw-r--r--src/mbgl/map/map.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/mbgl/map/map.cpp b/src/mbgl/map/map.cpp
index 7d57f6863e..d5a5923e6c 100644
--- a/src/mbgl/map/map.cpp
+++ b/src/mbgl/map/map.cpp
@@ -727,11 +727,7 @@ void Map::Impl::onStyleLoading() {
void Map::Impl::onStyleLoaded() {
if (!cameraMutated) {
- // Zoom first because it may constrain subsequent operations.
- map.setZoom(style->getDefaultZoom());
- map.setLatLng(style->getDefaultLatLng());
- map.setBearing(style->getDefaultBearing());
- map.setPitch(style->getDefaultPitch());
+ map.jumpTo(style->getDefaultCamera());
}
annotationManager.onStyleLoaded();