mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Keep state of reverse geocode button in sync with GPS data
So if the data is removed or invalid, don't allow reverse lookup. Otherwise do. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
b7bf5d0fb2
commit
7be0e1b1e7
1 changed files with 3 additions and 0 deletions
|
@ -236,6 +236,9 @@ void LocationInformationWidget::on_diveSiteCoordinates_textChanged(const QString
|
||||||
displayed_dive_site.longitude.udeg = longitude * 1000000;
|
displayed_dive_site.longitude.udeg = longitude * 1000000;
|
||||||
markChangedWidget(ui.diveSiteCoordinates);
|
markChangedWidget(ui.diveSiteCoordinates);
|
||||||
emit coordinatesChanged();
|
emit coordinatesChanged();
|
||||||
|
ui.geoCodeButton->setEnabled(latitude != 0 && longitude != 0);
|
||||||
|
} else {
|
||||||
|
ui.geoCodeButton->setEnabled(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
free((void *)coords);
|
free((void *)coords);
|
||||||
|
|
Loading…
Add table
Reference in a new issue