From 3de2130b6070bb9012d81e290fda452db42e069f Mon Sep 17 00:00:00 2001 From: Xavier ASUS Date: Tue, 27 Nov 2018 00:26:41 +0100 Subject: TILE_TAXIWAY_CORNER_GRASS_3 added to accepted tiles list. Building edition is now supported on MapEditor! LEVEL2.LVL now has some buildings laying around. --- Source/MapEditor/mygraphicsscene.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'Source/MapEditor/mygraphicsscene.cpp') diff --git a/Source/MapEditor/mygraphicsscene.cpp b/Source/MapEditor/mygraphicsscene.cpp index d0241ae..dcc7d1c 100644 --- a/Source/MapEditor/mygraphicsscene.cpp +++ b/Source/MapEditor/mygraphicsscene.cpp @@ -11,12 +11,12 @@ MyGraphicsScene::~MyGraphicsScene() } -void MyGraphicsScene::mousePressEvent(QGraphicsSceneMouseEvent *mouseEvent) +void MyGraphicsScene::mousePressEvent(QGraphicsSceneMouseEvent* const mouseEvent) { - QGraphicsItem *it = this->itemAt(mouseEvent->scenePos(), QTransform()); + const QGraphicsItem* const it = itemAt(mouseEvent->scenePos(), QTransform()); if (it != nullptr) - { + { emit positionClicked(mouseEvent->scenePos()); } else @@ -26,7 +26,7 @@ void MyGraphicsScene::mousePressEvent(QGraphicsSceneMouseEvent *mouseEvent) } } -void MyGraphicsScene::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *) +void MyGraphicsScene::mouseDoubleClickEvent(QGraphicsSceneMouseEvent* const mouseEvent) { - emit updateSelectedItem(); + emit updateSelectedItem(mouseEvent->button()); } -- cgit v1.2.3