KShare/cropeditor/drawing/drawitem.hpp

25 lines
487 B
C++
Raw Normal View History

2017-04-29 11:29:50 +02:00
#ifndef DRAWITEM_HPP
#define DRAWITEM_HPP
2017-05-01 11:28:54 +02:00
class DrawItem;
2017-04-29 12:08:02 +02:00
#include <QString>
#include <cropeditor/cropscene.hpp>
class DrawItem
{
public:
virtual ~DrawItem()
{
}
2017-04-29 12:08:02 +02:00
virtual QString name() = 0;
2017-05-01 11:28:54 +02:00
virtual void init(CropScene *scene)
{
Q_UNUSED(scene)
}
virtual void mouseDragEvent(QGraphicsSceneMouseEvent *e, CropScene *scene) = 0;
virtual void mouseDragEndEvent(QGraphicsSceneMouseEvent *e, CropScene *scene) = 0;
2017-04-29 12:08:02 +02:00
};
2017-04-29 11:29:50 +02:00
#endif // DRAWITEM_HPP