From f188995e556373e0f5e071f44af7a4d32adb6f64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Skowro=C5=84ski?= Date: Sun, 17 Apr 2016 09:44:32 +0200 Subject: [PATCH] QGraphicsItem * QGraphicsScene::itemAt(const QPointF & position) const is deprecated in Qt4. Use QGraphicsItem * QGraphicsScene::itemAt(const QPointF & position, const QTransform & deviceTransform) const instead. This change is Qt4/Qt5 neutral. --- src/Gui/DAGView/DAGModel.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Gui/DAGView/DAGModel.cpp b/src/Gui/DAGView/DAGModel.cpp index b7efe1070..140caf8d4 100644 --- a/src/Gui/DAGView/DAGModel.cpp +++ b/src/Gui/DAGView/DAGModel.cpp @@ -967,7 +967,7 @@ void Model::mousePressEvent(QGraphicsSceneMouseEvent* event) const GraphLinkRecord &record = findRecord(rect, *graphLink); //don't like that I am doing this again here after getRectFromPosition call. - QGraphicsItem *item = itemAt(event->scenePos()); + QGraphicsItem *item = itemAt(event->scenePos(), QTransform()); QGraphicsPixmapItem *pixmapItem = dynamic_cast(item); if (pixmapItem && (pixmapItem == (*theGraph)[record.vertex].visibleIcon.get())) { @@ -1061,7 +1061,7 @@ void Model::contextMenuEvent(QGraphicsSceneContextMenuEvent* event) const GraphLinkRecord &record = findRecord(rect, *graphLink); //don't like that I am doing this again here after getRectFromPosition call. - QGraphicsItem *item = itemAt(event->scenePos()); + QGraphicsItem *item = itemAt(event->scenePos(), QTransform()); QGraphicsPixmapItem *pixmapItem = dynamic_cast(item); if (pixmapItem && (pixmapItem == (*theGraph)[record.vertex].visibleIcon.get())) {