diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2014-10-30 13:01:09 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-10-30 13:03:50 -0700 |
commit | fa5c713f736e58ebcd49bbe2f07d1a20b2433ae2 (patch) | |
tree | 7fc384238aad771ad66cc9f80a1c8a1ebbba2c97 /qt-ui/maintab.cpp | |
parent | d2567f761a1cff48e46849eff8e3e09073751210 (diff) | |
download | subsurface-fa5c713f736e58ebcd49bbe2f07d1a20b2433ae2.tar.gz |
After editing tags, get the right tags into the displayed dive
We forgot to clear out the pre-existing tags. We did this for the actual
selected dives that were being edited, but not for the displayed_dive, so
deleted tags showed up again on screen (even though they were correctly
deleted from the selected dives in the dive list).
Fixes #732
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/maintab.cpp')
-rw-r--r-- | qt-ui/maintab.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/qt-ui/maintab.cpp b/qt-ui/maintab.cpp index 7b052e984..fcb3cd362 100644 --- a/qt-ui/maintab.cpp +++ b/qt-ui/maintab.cpp @@ -997,6 +997,8 @@ void MainTab::on_timeEdit_timeChanged(const QTime &time) void MainTab::saveTags() { struct dive *cd = current_dive; + taglist_free(displayed_dive.tag_list); + displayed_dive.tag_list = NULL; Q_FOREACH (const QString& tag, ui.tagWidget->getBlockStringList()) taglist_add_tag(&displayed_dive.tag_list, tag.toUtf8().data()); taglist_cleanup(&displayed_dive.tag_list); |