aboutsummaryrefslogtreecommitdiff
path: root/Source/MapEditor/mygraphicsscene.h
blob: ea416e0ce95627df8380d08cf9b539f364099223 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef MYGRAPHICSSCENE_H
#define MYGRAPHICSSCENE_H

#include <QGraphicsScene>
#include <QGraphicsSceneMouseEvent>
#include <QPointF>

class MyGraphicsScene : public QGraphicsScene
{
    Q_OBJECT

public:
    explicit MyGraphicsScene();
    ~MyGraphicsScene();

signals:
    void positionClicked(QPointF position);
    void noItemSelected(void);
    void updateSelectedItem(Qt::MouseButton button);

private:
    void mousePressEvent(QGraphicsSceneMouseEvent * const mouseEvent);
    void mouseDoubleClickEvent(QGraphicsSceneMouseEvent * const mouseEvent);

};

#endif // MYGRAPHICSSCENE_H