summaryrefslogtreecommitdiffstats
path: root/examples/widgets/graphicsview/dragdroprobot/robot.h
diff options
context:
space:
mode:
Diffstat (limited to 'examples/widgets/graphicsview/dragdroprobot/robot.h')
-rw-r--r--examples/widgets/graphicsview/dragdroprobot/robot.h26
1 files changed, 13 insertions, 13 deletions
diff --git a/examples/widgets/graphicsview/dragdroprobot/robot.h b/examples/widgets/graphicsview/dragdroprobot/robot.h
index a0c842e72c..6ab60756ee 100644
--- a/examples/widgets/graphicsview/dragdroprobot/robot.h
+++ b/examples/widgets/graphicsview/dragdroprobot/robot.h
@@ -55,9 +55,9 @@ public:
RobotPart(QGraphicsItem *parent = 0);
protected:
- void dragEnterEvent(QGraphicsSceneDragDropEvent *event);
- void dragLeaveEvent(QGraphicsSceneDragDropEvent *event);
- void dropEvent(QGraphicsSceneDragDropEvent *event);
+ void dragEnterEvent(QGraphicsSceneDragDropEvent *event) Q_DECL_OVERRIDE;
+ void dragLeaveEvent(QGraphicsSceneDragDropEvent *event) Q_DECL_OVERRIDE;
+ void dropEvent(QGraphicsSceneDragDropEvent *event) Q_DECL_OVERRIDE;
QColor color;
bool dragOver;
@@ -70,12 +70,12 @@ class RobotHead : public RobotPart
public:
RobotHead(QGraphicsItem *parent = 0);
- QRectF boundingRect() const;
- void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0);
+ QRectF boundingRect() const Q_DECL_OVERRIDE;
+ void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0) Q_DECL_OVERRIDE;
protected:
- void dragEnterEvent(QGraphicsSceneDragDropEvent *event);
- void dropEvent(QGraphicsSceneDragDropEvent *event);
+ void dragEnterEvent(QGraphicsSceneDragDropEvent *event) Q_DECL_OVERRIDE;
+ void dropEvent(QGraphicsSceneDragDropEvent *event) Q_DECL_OVERRIDE;
private:
QPixmap pixmap;
@@ -88,8 +88,8 @@ class RobotTorso : public RobotPart
public:
RobotTorso(QGraphicsItem *parent = 0);
- QRectF boundingRect() const;
- void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0);
+ QRectF boundingRect() const Q_DECL_OVERRIDE;
+ void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0) Q_DECL_OVERRIDE;
};
//! [2]
@@ -99,8 +99,8 @@ class RobotLimb : public RobotPart
public:
RobotLimb(QGraphicsItem *parent = 0);
- QRectF boundingRect() const;
- void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0);
+ QRectF boundingRect() const Q_DECL_OVERRIDE;
+ void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0) Q_DECL_OVERRIDE;
};
//! [3]
@@ -110,8 +110,8 @@ class Robot : public RobotPart
public:
Robot(QGraphicsItem *parent = 0);
- QRectF boundingRect() const;
- void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0);
+ QRectF boundingRect() const Q_DECL_OVERRIDE;
+ void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0) Q_DECL_OVERRIDE;
};
//! [4]