RetroShare/retroshare-gui/src/gui/People/CircleItem.h
csoler b6c68d1812 - started changing distant chat so that it works with GXS ids instead of PGP ids. Something is still broken in
service control. Crypto is not done yet => distant chat is unencrypted.
- changed GUI for distant chat. Removed invitation system.
- added menu item to distant chat GXS ids from IdentityItem (only entry point for now).
- fixed bug in chat lobbies causing re-connexion of lobbies not to happen everytime (bug reported bu Lain)



git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7378 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-05-25 21:43:05 +00:00

49 lines
1.2 KiB
C++

#pragma once
#include <QGraphicsItem>
#include <retroshare/rsgxscircles.h>
class CircleItem: public QObject, public QGraphicsItem
{
Q_OBJECT
public:
CircleItem(const RsGroupMetaData& gxs_group_info,const RsGxsCircleDetails& details) ;
QRectF boundingRect() const ;
//QPainterPath shape() const ;
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) ;
//static QImage makeDefaultIcon(const RsGxsGroupId& id) ;
static const int IMG_SIZE = 32;
static const int CRC_SIZE = 128;
static CircleItem *_selected_node ;
const RsGroupMetaData& groupInfo() const { return _group_info ; }
signals:
void itemChanged() ;
private:
virtual void hoverEnterEvent(QGraphicsSceneHoverEvent *e);
virtual void hoverLeaveEvent(QGraphicsSceneHoverEvent *e);
virtual QVariant itemChange(GraphicsItemChange change,const QVariant& value) ;
virtual void mousePressEvent(QGraphicsSceneMouseEvent *event);
virtual void mouseReleaseEvent(QGraphicsSceneMouseEvent *event);
virtual void contextMenuEvent(QGraphicsSceneContextMenuEvent *) ;
RsGroupMetaData _group_info ;
RsGxsCircleDetails _circle_details ;
bool mDeterminedBB;
bool mBBWidth;
bool _selected ;
std::vector<float> _angles ;
};