mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Fix showing the stuff on the canvas in the right positions.
Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
This commit is contained in:
parent
ea5353025f
commit
9a40333067
1 changed files with 2 additions and 4 deletions
|
@ -163,9 +163,8 @@ void ProfileGraphicsView::mouseMoveEvent(QMouseEvent* event)
|
||||||
ensureVisible(event->pos().x(), event->pos().y(), 10, 10, 100, 100);
|
ensureVisible(event->pos().x(), event->pos().y(), 10, 10, 100, 100);
|
||||||
toolTip->setPos(mapToScene(toolTipPos).x(), mapToScene(toolTipPos).y());
|
toolTip->setPos(mapToScene(toolTipPos).x(), mapToScene(toolTipPos).y());
|
||||||
|
|
||||||
if (zoomLevel < 0){
|
if (zoomLevel < 0)
|
||||||
QGraphicsView::mouseMoveEvent(event);
|
QGraphicsView::mouseMoveEvent(event);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ProfileGraphicsView::eventFilter(QObject* obj, QEvent* event)
|
bool ProfileGraphicsView::eventFilter(QObject* obj, QEvent* event)
|
||||||
|
@ -322,8 +321,7 @@ void ProfileGraphicsView::plot(struct dive *d)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
QRectF curerntRect = scene()->itemsBoundingRect();
|
scene()->setSceneRect(scene()->itemsBoundingRect());
|
||||||
scene()->setSceneRect( -10, -10, curerntRect.width() + 10, curerntRect.height() +10 );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ProfileGraphicsView::plot_depth_scale()
|
void ProfileGraphicsView::plot_depth_scale()
|
||||||
|
|
Loading…
Add table
Reference in a new issue