mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Stop clicks on the globe from changing dive list selection while editing
This caused us to get royally confused when manually adding a dive and trying to set the location through the marble widget. Fixes # 229 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
f41651439c
commit
9ead871d64
3 changed files with 10 additions and 0 deletions
|
|
@ -71,6 +71,10 @@ GlobeGPS::GlobeGPS(QWidget* parent) : MarbleWidget(parent), loadedDives(0)
|
|||
|
||||
void GlobeGPS::mouseClicked(qreal lon, qreal lat, GeoDataCoordinates::Unit unit)
|
||||
{
|
||||
// don't mess with the selection while the user is editing a dive
|
||||
if (mainWindow()->information()->isEditing())
|
||||
return;
|
||||
|
||||
GeoDataCoordinates here(lon, lat, unit);
|
||||
long lon_udeg = rint(1000000 * here.longitude(GeoDataCoordinates::Degree));
|
||||
long lat_udeg = rint(1000000 * here.latitude(GeoDataCoordinates::Degree));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue