mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Only replot the dive if maxDepth > oldMaxDepth on plan / add mode.
This fixes the "impossible to work with" planner with the mouse now the dive will only grow and not shrink untill you release the mouse. Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
4da7dee8cf
commit
1ac0b00662
4 changed files with 50 additions and 3 deletions
|
@ -107,6 +107,8 @@ slots: // Necessary to call from QAction's signals.
|
|||
void keyLeftAction();
|
||||
void keyRightAction();
|
||||
|
||||
void divePlannerHandlerClicked();
|
||||
void divePlannerHandlerReleased();
|
||||
protected:
|
||||
virtual void resizeEvent(QResizeEvent *event);
|
||||
virtual void wheelEvent(QWheelEvent *event);
|
||||
|
@ -115,6 +117,7 @@ protected:
|
|||
virtual void mouseDoubleClickEvent(QMouseEvent *event);
|
||||
virtual void mousePressEvent(QMouseEvent *event);
|
||||
virtual void mouseReleaseEvent(QMouseEvent *event);
|
||||
|
||||
private: /*methods*/
|
||||
void fixBackgroundPos();
|
||||
void scrollViewTo(const QPoint &pos);
|
||||
|
@ -169,7 +172,9 @@ private:
|
|||
friend class DiveHandler;
|
||||
QHash<Qt::Key, QAction *> actionsForKeys;
|
||||
bool shouldCalculateMaxTime;
|
||||
bool shouldCalculateMaxDepth;
|
||||
int maxtime;
|
||||
int maxdepth;
|
||||
};
|
||||
|
||||
#endif // PROFILEWIDGET2_H
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue