summaryrefslogtreecommitdiff
path: root/include/mbgl/util/geo.hpp
diff options
context:
space:
mode:
authorBruno de Oliveira Abinader <bruno@mapbox.com>2016-03-01 14:17:21 +0000
committerBruno de Oliveira Abinader <bruno@mapbox.com>2016-03-01 20:58:54 +0000
commitc6757b9a9b004c566c9ff0b0715d336e668e1410 (patch)
tree6ae5a7c7fb29f5d68e2fb9e94b8da892bacbad2e /include/mbgl/util/geo.hpp
parentfde0ab98eedd77e652e1232605e4bc96f9fa65b9 (diff)
downloadqtlocation-mapboxgl-c6757b9a9b004c566c9ff0b0715d336e668e1410.tar.gz
[core] Added DEGREES_MAX as constant value
Diffstat (limited to 'include/mbgl/util/geo.hpp')
-rw-r--r--include/mbgl/util/geo.hpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/mbgl/util/geo.hpp b/include/mbgl/util/geo.hpp
index 5636cd0bdf..755abeda21 100644
--- a/include/mbgl/util/geo.hpp
+++ b/include/mbgl/util/geo.hpp
@@ -33,7 +33,7 @@ public:
coordinate so that interpolating between the two endpoints will cross it. */
void unwrapForShortestPath(const LatLng& start) {
if (std::abs(start.longitude) + std::abs(longitude) > util::LONGITUDE_MAX) {
- longitude += (start.longitude > 0 && longitude < 0) ? 360 : -360;
+ longitude += (start.longitude > 0 && longitude < 0) ? util::DEGREES_MAX : -util::DEGREES_MAX;
}
}