cleanup: unify the ProfileWidget2::shouldCalculateMax* variables

The shouldCalcluateMaxTime and shouldCalculateMaxDepth member
variables of ProfileWidget2 are set to false during drag-mode to
avoid strange shrinking of the graph. They always adopt the
same value. Therefore, replace by a single shouldCalculateMax
boolean.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2021-07-29 17:19:50 +02:00 committed by Dirk Hohndel
parent 15c524804a
commit f16a7c262e
2 changed files with 11 additions and 13 deletions

View file

@ -253,8 +253,7 @@ private:
#endif
friend class DiveHandler;
QHash<Qt::Key, QAction *> actionsForKeys;
bool shouldCalculateMaxTime;
bool shouldCalculateMaxDepth;
bool shouldCalculateMax; // Calculate maximum time and depth (default). False when dragging handles.
int maxtime;
int maxdepth;
double fontPrintScale;