mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
planner: move clearing of model into loadFromDive() function
Both loadFromDive() callers were clearing the model before calling loadFromDive(). Move the clearing into that function since it makes no sense to load into a non-cleared model. Apparently this changes the way that no-cylinder dives are treated and the code in ProfileWidget2::repositionDiveHandlers() must now explicitly check for that condition. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
02ef58a48b
commit
e419ebf55a
5 changed files with 8 additions and 6 deletions
|
@ -1514,7 +1514,6 @@ void MainWindow::editCurrentDive()
|
|||
return;
|
||||
|
||||
disableShortcuts();
|
||||
DivePlannerPointsModel::instance()->clear();
|
||||
DivePlannerPointsModel::instance()->setPlanMode(DivePlannerPointsModel::ADD);
|
||||
graphics->setAddState();
|
||||
setApplicationState(ApplicationState::EditDive);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue