diff options
author | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2015-11-17 17:19:54 +0200 |
---|---|---|
committer | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2015-11-18 09:37:27 +0200 |
commit | adfac6f0615b7f79da2c80d0580428a92e9f0089 (patch) | |
tree | b6cac5234e13cdd5148efdbb8f3cd1e9c7ed349f /include/mbgl/map/map.hpp | |
parent | cb9b397985b98a75aa9fa5e6f2b135c205f7cafd (diff) | |
download | qtlocation-mapboxgl-adfac6f0615b7f79da2c80d0580428a92e9f0089.tar.gz |
[core] Added ConstrainMode::{HeightOnly,WidthAndHeight}
ConstrainMode gives flexibility to our engine to choose between
constraining both vertically and horizontally, or just vertically
(default behavior).
Constrain in both axis means we can no longer pan the map beyond the map
boundaries. This fixes an issue where e.g. annotations disappear upon
crossing the map boundaries.
Diffstat (limited to 'include/mbgl/map/map.hpp')
-rw-r--r-- | include/mbgl/map/map.hpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/mbgl/map/map.hpp b/include/mbgl/map/map.hpp index f2e605141b..c190088088 100644 --- a/include/mbgl/map/map.hpp +++ b/include/mbgl/map/map.hpp @@ -45,7 +45,8 @@ class Map : private util::noncopyable { public: explicit Map(View&, FileSource&, MapMode mapMode = MapMode::Continuous, - GLContextMode contextMode = GLContextMode::Unique); + GLContextMode contextMode = GLContextMode::Unique, + ConstrainMode constrainMode = ConstrainMode::HeightOnly); ~Map(); // Pauses the render thread. The render thread will stop running but will not be terminated and will not lose state until resumed. |