From dbb84188c2d323365e100a47cdddd6e793d5e068 Mon Sep 17 00:00:00 2001 From: Sergey Starosek Date: Sat, 25 May 2013 14:14:16 +0300 Subject: Fix GPS coordinates rounding. Better round the coordinates. Signed-off-by: Sergey Starosek Signed-off-by: Dirk Hohndel --- qt-ui/globe.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qt-ui/globe.cpp b/qt-ui/globe.cpp index 5f99eaf3d..0bd8f3d83 100644 --- a/qt-ui/globe.cpp +++ b/qt-ui/globe.cpp @@ -110,8 +110,8 @@ void GlobeGPS::changeDiveGeoPosition(qreal lon, qreal lat, GeoDataCoordinates::U return; } - editingDiveCoords->latitude.udeg = lat * 1000000.0; - editingDiveCoords->longitude.udeg = lon * 1000000.0; + editingDiveCoords->latitude.udeg = lrint(lat * 1000000.0); + editingDiveCoords->longitude.udeg = lrint(lon * 1000000.0); centerOn(lon, lat, true); reload(); editingDiveCoords = 0; -- cgit v1.2.3-70-g09d2