mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Dive edit: do a better job noticing when the coordinates were changed
Previously the code could get confused by edits (including trivial things like deleting the coordinates). It seems much more reliable to simply compare the coordinates of the edited dive with the ones in the current dive before the edits. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
a26719c541
commit
95cb4e85ee
1 changed files with 2 additions and 1 deletions
|
@ -663,7 +663,8 @@ void MainTab::acceptChanges()
|
|||
}
|
||||
}
|
||||
}
|
||||
if (ui.coordinates->isModified()) {
|
||||
if (editedDive.latitude.udeg != current_dive->latitude.udeg ||
|
||||
editedDive.longitude.udeg != current_dive->longitude.udeg) {
|
||||
EDIT_SELECTED_DIVES(gpsHasChanged(mydive, cd, ui.coordinates->text(), 0));
|
||||
}
|
||||
if (tagsChanged(&editedDive, cd))
|
||||
|
|
Loading…
Add table
Reference in a new issue