wagmare
13th May 2009, 07:54
hi friends,
i am following the padnavigator example ... /qt4.4.3/example/graphicsview/padnavigator
in this example
in roundrectitem.h
the code is
class RoundRectItem : public QObject, public QGraphicsRectItem
{
Q_OBJECT
public:
RoundRectItem(const QRectF &rect, const QBrush &brush, QWidget *embeddedWidget = 0);
why we want to inherit QObject and also the Q_OBJECT macro .. either one is enough ...?
i am following the padnavigator example ... /qt4.4.3/example/graphicsview/padnavigator
in this example
in roundrectitem.h
the code is
class RoundRectItem : public QObject, public QGraphicsRectItem
{
Q_OBJECT
public:
RoundRectItem(const QRectF &rect, const QBrush &brush, QWidget *embeddedWidget = 0);
why we want to inherit QObject and also the Q_OBJECT macro .. either one is enough ...?