diff options
Diffstat (limited to 'mobile-widgets/qmlmapwidgethelper.cpp')
-rw-r--r-- | mobile-widgets/qmlmapwidgethelper.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/mobile-widgets/qmlmapwidgethelper.cpp b/mobile-widgets/qmlmapwidgethelper.cpp index faa0c5f84..7fceccdfa 100644 --- a/mobile-widgets/qmlmapwidgethelper.cpp +++ b/mobile-widgets/qmlmapwidgethelper.cpp @@ -18,10 +18,8 @@ void MapWidgetHelper::centerOnDiveSite(struct dive_site *ds) qreal longitude = ds->longitude.udeg / 1000000.0;
qreal latitude = ds->latitude.udeg / 1000000.0;
-
- QMetaObject::invokeMethod(m_map, "centerOnCoordinates",
- Q_ARG(QVariant, latitude),
- Q_ARG(QVariant, longitude));
+ QVariant coord = QVariant::fromValue(QGeoCoordinate(latitude, longitude));
+ QMetaObject::invokeMethod(m_map, "centerOnCoordinate", Q_ARG(QVariant, coord));
}
void MapWidgetHelper::reloadMapLocations()
|