Planner: update maxdepth and best mixes when profile changed by mouse

Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Rick Walsh 2016-07-06 22:40:38 +10:00 committed by Dirk Hohndel
parent bb31517951
commit 54871debfb

View file

@ -674,6 +674,8 @@ void DivePlannerPointsModel::editStop(int row, divedatapoint newData)
return;
divepoints[row] = newData;
std::sort(divepoints.begin(), divepoints.end(), divePointsLessThan);
if (updateMaxDepth())
CylindersModel::instance()->updateBestMixes();
emit dataChanged(createIndex(0, 0), createIndex(rowCount() - 1, COLUMNS - 1));
}