2018-03-11 16:02:15 +00:00
|
|
|
#ifndef SKELETON_EDIT_NODE_ITEM_H
|
|
|
|
#define SKELETON_EDIT_NODE_ITEM_H
|
|
|
|
#include <QGraphicsEllipseItem>
|
|
|
|
|
2018-03-12 09:41:16 +00:00
|
|
|
class SkeletonEditEdgeItem;
|
|
|
|
|
2018-03-11 16:02:15 +00:00
|
|
|
class SkeletonEditNodeItem : public QGraphicsEllipseItem
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
SkeletonEditNodeItem(const QRectF &rect, QGraphicsItem *parent = 0);
|
|
|
|
QPointF origin();
|
2018-03-12 05:27:22 +00:00
|
|
|
float radius();
|
2018-03-11 16:02:15 +00:00
|
|
|
void setHighlighted(bool highlited);
|
|
|
|
void setIsNextStartNode(bool isNextStartNode);
|
2018-03-12 09:41:16 +00:00
|
|
|
bool isSlave();
|
|
|
|
bool isMaster();
|
|
|
|
void setMaster(SkeletonEditNodeItem *nodeItem);
|
|
|
|
void setSlave(SkeletonEditNodeItem *nodeItem);
|
|
|
|
SkeletonEditNodeItem *master();
|
|
|
|
SkeletonEditNodeItem *slave();
|
2018-03-11 16:02:15 +00:00
|
|
|
private:
|
|
|
|
bool m_highlighted;
|
|
|
|
bool m_isNextStartNode;
|
2018-03-12 09:41:16 +00:00
|
|
|
SkeletonEditNodeItem *m_master;
|
|
|
|
SkeletonEditNodeItem *m_slave;
|
2018-03-11 16:02:15 +00:00
|
|
|
void updateBorder();
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|