2015-10-05 01:43:48 +02:00
|
|
|
#ifndef POIITEM_H
|
|
|
|
#define POIITEM_H
|
|
|
|
|
|
|
|
#include <QGraphicsItem>
|
2015-11-23 02:37:08 +01:00
|
|
|
#include "poi.h"
|
2015-10-05 01:43:48 +02:00
|
|
|
|
|
|
|
class POIItem : public QGraphicsItem
|
|
|
|
{
|
|
|
|
public:
|
2015-11-23 02:37:08 +01:00
|
|
|
POIItem(const Entry &entry, QGraphicsItem *parent = 0);
|
|
|
|
const Entry &entry() const {return _entry;}
|
2015-10-05 01:43:48 +02:00
|
|
|
|
|
|
|
QRectF boundingRect() const {return _boundingRect;}
|
|
|
|
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option,
|
|
|
|
QWidget *widget);
|
|
|
|
|
|
|
|
private:
|
|
|
|
void updateBoundingRect();
|
|
|
|
|
2015-11-23 02:37:08 +01:00
|
|
|
Entry _entry;
|
2015-10-05 01:43:48 +02:00
|
|
|
QRectF _boundingRect;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // POIITEM_H
|