porymap/include/ui/graphicsview.h

30 lines
648 B
C
Raw Normal View History

2018-09-27 00:30:05 +01:00
#ifndef GRAPHICSVIEW_H
#define GRAPHICSVIEW_H
#include "overlay.h"
2018-09-27 00:30:05 +01:00
#include <QGraphicsView>
#include <QMouseEvent>
class Editor;
class GraphicsView : public QGraphicsView
{
public:
GraphicsView() : QGraphicsView() {}
GraphicsView(QWidget *parent) : QGraphicsView(parent) {}
public:
// GraphicsView_Object object;
Editor *editor;
Overlay overlay;
2018-09-27 00:30:05 +01:00
protected:
void mousePressEvent(QMouseEvent *event);
void mouseMoveEvent(QMouseEvent *event);
void mouseReleaseEvent(QMouseEvent *event);
void drawForeground(QPainter *painter, const QRectF &rect);
2018-09-27 00:30:05 +01:00
};
//Q_DECLARE_METATYPE(GraphicsView)
#endif // GRAPHICSVIEW_H