diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2019-03-14 23:28:45 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2019-04-12 18:19:07 +0300 |
commit | b5d4d88fe596fa91a3f3491fe8acc220a0df7b72 (patch) | |
tree | e198af14ac0c2a72609aa66f0c644821c650650e /desktop-widgets/command_divesite.cpp | |
parent | 0b851d723e1b57fd2065c268977e023cfb364066 (diff) | |
download | subsurface-b5d4d88fe596fa91a3f3491fe8acc220a0df7b72.tar.gz |
Dive site: remove edit mode from dive location widget
Since no dive site field editing enters edit mode anymore,
the whole edit mode state and code can be removed from the
widget.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'desktop-widgets/command_divesite.cpp')
-rw-r--r-- | desktop-widgets/command_divesite.cpp | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/desktop-widgets/command_divesite.cpp b/desktop-widgets/command_divesite.cpp index 5e2a8b18a..91a6dbe81 100644 --- a/desktop-widgets/command_divesite.cpp +++ b/desktop-widgets/command_divesite.cpp @@ -208,17 +208,8 @@ void EditDiveSiteCountry::undo() redo(); } -// Parse GPS text into location_t -static location_t parseGpsText(const QString &text) -{ - double lat, lon; - if (parseGpsText(text, &lat, &lon)) - return create_location(lat, lon); - return { {0}, {0} }; -} - -EditDiveSiteLocation::EditDiveSiteLocation(dive_site *dsIn, const QString &location) : ds(dsIn), - value(parseGpsText(location)) +EditDiveSiteLocation::EditDiveSiteLocation(dive_site *dsIn, const location_t location) : ds(dsIn), + value(location) { setText(tr("Edit dive site location")); } |