From 40755987edaa711cb55cf41d094f2728a67d37d0 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Sun, 15 Apr 2018 14:43:26 -0700 Subject: Qt: don't use member function that requires Qt 5.8 This should have been caught by our build check, but it turns out that that one isn't correctly reflected in its Travis status. Oops. Signed-off-by: Dirk Hohndel --- core/gpslocation.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core/gpslocation.cpp') diff --git a/core/gpslocation.cpp b/core/gpslocation.cpp index 79a44379c..4e48fa024 100644 --- a/core/gpslocation.cpp +++ b/core/gpslocation.cpp @@ -175,7 +175,7 @@ void GpsLocation::newPosition(QGeoPositionInfo pos) if (!nr || waitingForPosition || delta > prefs.time_threshold || lastCoord.distanceTo(pos.coordinate()) > prefs.distance_threshold) { QString msg("received new position %1 after delta %2 threshold %3 (now %4 last %5)"); - status(qPrintable(msg.arg(pos.coordinate().toString()).arg(delta).arg(prefs.time_threshold).arg(pos.timestamp().toString()).arg(QDateTime().fromSecsSinceEpoch(lastTime).toString()))); + status(qPrintable(msg.arg(pos.coordinate().toString()).arg(delta).arg(prefs.time_threshold).arg(pos.timestamp().toString()).arg(QDateTime().fromMSecsSinceEpoch(lastTime * 1000).toString()))); waitingForPosition = false; acquiredPosition(); gpsTracker gt; @@ -185,7 +185,7 @@ void GpsLocation::newPosition(QGeoPositionInfo pos) gt.longitude.udeg = lrint(pos.coordinate().longitude() * 1000000); addFixToStorage(gt); gpsTracker gtNew = m_trackers.last(); - qDebug() << "newest fix is now at" << QDateTime().fromSecsSinceEpoch(gtNew.when - gettimezoneoffset(gtNew.when)).toString(); + qDebug() << "newest fix is now at" << QDateTime().fromMSecsSinceEpoch(gtNew.when - gettimezoneoffset(gtNew.when) * 1000).toString(); } } -- cgit v1.2.3-70-g09d2