mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-30 22:20:21 +00:00
Make sure we keep our notion of what's selected in sync with the UI
When editing a dive, a group of dives or a trip we need to make sure that we don't lose track of which dives and trips were selected. Otherwise we might act on dives that DON'T appear selected in the UI but that we think are still selected. Fixes #304 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3fd39a7a87
commit
cc91cad890
1 changed files with 2 additions and 0 deletions
|
@ -549,8 +549,10 @@ void MainTab::acceptChanges()
|
|||
// now comes the scary moment... we need to re-sort dive table in case this dive wasn't the last
|
||||
// so now all pointers become invalid
|
||||
// fingers crossed that we aren't holding on to anything here
|
||||
mainWindow()->dive_list()->rememberSelection();
|
||||
sort_table(&dive_table);
|
||||
mainWindow()->refreshDisplay();
|
||||
mainWindow()->dive_list()->restoreSelection();
|
||||
}
|
||||
|
||||
void MainTab::resetPallete()
|
||||
|
|
Loading…
Reference in a new issue