mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Location service: check presence of location source
In theory this should only report a location service if this is a satellite based service, but sadly geoclue appears to claim that there is a satellite based service in my Linux VM - so I'm doubtful that this does what the documentation says it does. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
ff5bd062f6
commit
ca5b751610
2 changed files with 6 additions and 0 deletions
|
@ -31,6 +31,11 @@ GpsLocation::GpsLocation(void (*showMsgCB)(const char *), QObject *parent)
|
|||
userAgent = getUserAgent();
|
||||
}
|
||||
|
||||
bool GpsLocation::hasLocationsSource()
|
||||
{
|
||||
return gpsSource != 0 && (gpsSource->supportedPositioningMethods() & QGeoPositionInfoSource::SatellitePositioningMethods);
|
||||
}
|
||||
|
||||
void GpsLocation::serviceEnable(bool toggle)
|
||||
{
|
||||
if (!gpsSource) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue