mirror of
https://github.com/subsurface/subsurface.git
synced 2024-12-01 06:30:26 +00:00
Avoid precision loss on GPS fixes
It appears that the Qt documentation might be incorrect. It claims that the precision value is digits after the decimal point, but we have seen examples where the values posted to the server appear to have a total of 6 digits, including the digits ahead of the decimal point. Upping this to 9 shouldn't hurt if Qt gets fixed, but should work around the issue reported by a tester. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
260cd14a2b
commit
c2eeda44e6
1 changed files with 2 additions and 2 deletions
|
@ -506,8 +506,8 @@ void GpsLocation::uploadToServer()
|
|||
data.addQueryItem("login", prefs.userid);
|
||||
data.addQueryItem("dive_date", dt.toString("yyyy-MM-dd"));
|
||||
data.addQueryItem("dive_time", dt.toString("hh:mm"));
|
||||
data.addQueryItem("dive_latitude", QString::number(gt.latitude.udeg / 1000000.0, 'f', 6));
|
||||
data.addQueryItem("dive_longitude", QString::number(gt.longitude.udeg / 1000000.0, 'f', 6));
|
||||
data.addQueryItem("dive_latitude", QString::number(gt.latitude.udeg / 1000000.0, 'f', 9));
|
||||
data.addQueryItem("dive_longitude", QString::number(gt.longitude.udeg / 1000000.0, 'f', 9));
|
||||
if (gt.name.isEmpty())
|
||||
gt.name = "Auto-created dive";
|
||||
data.addQueryItem("dive_name", gt.name);
|
||||
|
|
Loading…
Reference in a new issue