headers: Add missing override and remove redundant virtual

Change-Id: Ifa816ebcd79372afca42dbd0dc0ecde006bb688a
Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This commit is contained in:
Alexander Volkov 2016-12-05 00:03:04 +03:00
parent 485e9fdf48
commit 3dd96630a2
43 changed files with 212 additions and 212 deletions

View File

@ -49,7 +49,7 @@ class QQmlDebuggerServiceFactory : public QQmlDebugServiceFactory
Q_OBJECT
Q_PLUGIN_METADATA(IID QQmlDebugServiceFactory_iid FILE "qqmldebuggerservice.json")
public:
QQmlDebugService *create(const QString &key);
QQmlDebugService *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -112,7 +112,7 @@ class ScopeJob: public CollectJob
public:
ScopeJob(QV4DataCollector *collector, int frameNr, int scopeNr);
void run();
void run() override;
bool wasSuccessful() const;
};

View File

@ -81,7 +81,7 @@ class SelectionHighlight : public Highlight
public:
SelectionHighlight(const QString &name, QQuickItem *item, QQuickItem *parent);
void paint(QPainter *painter);
void paint(QPainter *painter) override;
void showName(const QPointF &displayPoint);
private:
@ -104,7 +104,7 @@ public:
setZ(1); // hover highlight on top of selection highlight
}
void paint(QPainter *painter);
void paint(QPainter *painter) override;
};
} // namespace QmlJSDebugger

View File

@ -64,7 +64,7 @@ class QQmlInspectorServiceFactory : public QQmlDebugServiceFactory
Q_OBJECT
Q_PLUGIN_METADATA(IID QQmlDebugServiceFactory_iid FILE "qqmlinspectorservice.json")
public:
QQmlDebugService *create(const QString &key);
QQmlDebugService *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -78,7 +78,7 @@ public:
void setEnabled(bool enabled);
protected:
bool eventFilter(QObject *, QEvent *);
bool eventFilter(QObject *, QEvent *) override;
private:
QQuickItem *m_overlay;

View File

@ -50,7 +50,7 @@ class QLocalClientConnectionFactory : public QQmlDebugServerConnectionFactory
Q_PLUGIN_METADATA(IID QQmlDebugServerConnectionFactory_iid FILE "qlocalclientconnection.json")
Q_INTERFACES(QQmlDebugServerConnectionFactory)
public:
QQmlDebugServerConnection *create(const QString &key);
QQmlDebugServerConnection *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -68,10 +68,10 @@ public:
QDebugMessageServiceImpl(QObject *parent = 0);
void sendDebugMessage(QtMsgType type, const QMessageLogContext &ctxt, const QString &buf);
void synchronizeTime(const QElapsedTimer &otherTimer);
void synchronizeTime(const QElapsedTimer &otherTimer) override;
protected:
void stateChanged(State);
void stateChanged(State) override;
private:
friend class QQmlDebuggerServiceFactory;

View File

@ -49,7 +49,7 @@ class QDebugMessageServiceFactory : public QQmlDebugServiceFactory
Q_OBJECT
Q_PLUGIN_METADATA(IID QQmlDebugServiceFactory_iid FILE "qdebugmessageservice.json")
public:
QQmlDebugService *create(const QString &key);
QQmlDebugService *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -78,7 +78,7 @@ class QQmlNativeDebugConnectorFactory : public QQmlDebugConnectorFactory
Q_OBJECT
Q_PLUGIN_METADATA(IID QQmlDebugConnectorFactory_iid FILE "qqmlnativedebugconnector.json")
public:
QQmlDebugConnector *create(const QString &key);
QQmlDebugConnector *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -49,7 +49,7 @@ class QQmlNativeDebugServiceFactory : public QQmlDebugServiceFactory
Q_OBJECT
Q_PLUGIN_METADATA(IID QQmlDebugServiceFactory_iid FILE "qqmlnativedebugservice.json")
public:
QQmlDebugService *create(const QString &key);
QQmlDebugService *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -60,7 +60,7 @@ class QQmlProfilerServiceFactory : public QQmlDebugServiceFactory
Q_OBJECT
Q_PLUGIN_METADATA(IID QQmlDebugServiceFactory_iid FILE "qqmlprofilerservice.json")
public:
QQmlDebugService *create(const QString &key);
QQmlDebugService *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -61,7 +61,7 @@ class QQuickProfilerAdapterFactory : public QQmlAbstractProfilerAdapterFactory
Q_OBJECT
Q_PLUGIN_METADATA(IID QQmlAbstractProfilerAdapterFactory_iid FILE "qquickprofileradapter.json")
public:
QQmlAbstractProfilerAdapter *create(const QString &key);
QQmlAbstractProfilerAdapter *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -63,7 +63,7 @@ class QQmlDebugServerFactory : public QQmlDebugConnectorFactory
// QQmlDebugServer is for connection plugins.
Q_PLUGIN_METADATA(IID QQmlDebugConnectorFactory_iid FILE "qqmldebugserver.json")
public:
QQmlDebugConnector *create(const QString &key);
QQmlDebugConnector *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -50,7 +50,7 @@ class QTcpServerConnectionFactory : public QQmlDebugServerConnectionFactory
Q_PLUGIN_METADATA(IID QQmlDebugServerConnectionFactory_iid FILE "qtcpserverconnection.json")
Q_INTERFACES(QQmlDebugServerConnectionFactory)
public:
QQmlDebugServerConnection *create(const QString &key);
QQmlDebugServerConnection *create(const QString &key) override;
};
QT_END_NAMESPACE

View File

@ -218,11 +218,11 @@ public:
*/
static void updateAnimationTimer();
void restartAnimationTimer();
void updateAnimationsTime(qint64 timeStep);
void restartAnimationTimer() override;
void updateAnimationsTime(qint64 timeStep) override;
//useful for profiling/debugging
int runningAnimationCount() { return animations.count(); }
int runningAnimationCount() override { return animations.count(); }
bool hasStartAnimationPending() const { return startAnimationPending; }

View File

@ -62,14 +62,14 @@ public:
QContinuingAnimationGroupJob();
~QContinuingAnimationGroupJob();
int duration() const { return -1; }
int duration() const override { return -1; }
protected:
void updateCurrentTime(int currentTime);
void updateState(QAbstractAnimationJob::State newState, QAbstractAnimationJob::State oldState);
void updateDirection(QAbstractAnimationJob::Direction direction);
void uncontrolledAnimationFinished(QAbstractAnimationJob *animation);
void debugAnimation(QDebug d) const;
void updateCurrentTime(int currentTime) override;
void updateState(QAbstractAnimationJob::State newState, QAbstractAnimationJob::State oldState) override;
void updateDirection(QAbstractAnimationJob::Direction direction) override;
void uncontrolledAnimationFinished(QAbstractAnimationJob *animation) override;
void debugAnimation(QDebug d) const override;
};
QT_END_NAMESPACE

View File

@ -62,12 +62,12 @@ public:
explicit QPauseAnimationJob(int duration = 250);
~QPauseAnimationJob();
int duration() const;
int duration() const override;
void setDuration(int msecs);
protected:
void updateCurrentTime(int);
void debugAnimation(QDebug d) const;
void updateCurrentTime(int) override;
void debugAnimation(QDebug d) const override;
private:
//definition

View File

@ -63,16 +63,16 @@ public:
QSequentialAnimationGroupJob();
~QSequentialAnimationGroupJob();
int duration() const;
int duration() const override;
QAbstractAnimationJob *currentAnimation() const { return m_currentAnimation; }
protected:
void updateCurrentTime(int);
void updateState(QAbstractAnimationJob::State newState, QAbstractAnimationJob::State oldState);
void updateDirection(QAbstractAnimationJob::Direction direction);
void uncontrolledAnimationFinished(QAbstractAnimationJob *animation);
void debugAnimation(QDebug d) const;
void updateCurrentTime(int) override;
void updateState(QAbstractAnimationJob::State newState, QAbstractAnimationJob::State oldState) override;
void updateDirection(QAbstractAnimationJob::Direction direction) override;
void uncontrolledAnimationFinished(QAbstractAnimationJob *animation) override;
void debugAnimation(QDebug d) const override;
private:
struct AnimationIndex
@ -91,8 +91,8 @@ private:
void setCurrentAnimation(QAbstractAnimationJob *anim, bool intermediate = false);
void activateCurrentAnimation(bool intermediate = false);
void animationInserted(QAbstractAnimationJob *anim);
void animationRemoved(QAbstractAnimationJob *anim,QAbstractAnimationJob*,QAbstractAnimationJob*);
void animationInserted(QAbstractAnimationJob *anim) override;
void animationRemoved(QAbstractAnimationJob *anim, QAbstractAnimationJob *, QAbstractAnimationJob *) override;
bool atEnd() const;

View File

@ -80,61 +80,61 @@ public:
InstructionSelection(QQmlEnginePrivate *qmlEngine, QV4::ExecutableAllocator *execAllocator, IR::Module *module, QV4::Compiler::JSUnitGenerator *jsGenerator, EvalISelFactory *iselFactory);
~InstructionSelection();
virtual void run(int functionIndex);
void run(int functionIndex) override;
protected:
virtual QQmlRefPointer<QV4::CompiledData::CompilationUnit> backendCompileStep();
QQmlRefPointer<QV4::CompiledData::CompilationUnit> backendCompileStep() override;
virtual void callBuiltinInvalid(IR::Name *func, IR::ExprList *args, IR::Expr *result);
virtual void callBuiltinTypeofQmlContextProperty(IR::Expr *base, IR::Member::MemberKind kind, int propertyIndex, IR::Expr *result);
virtual void callBuiltinTypeofMember(IR::Expr *base, const QString &name, IR::Expr *result);
virtual void callBuiltinTypeofSubscript(IR::Expr *base, IR::Expr *index, IR::Expr *result);
virtual void callBuiltinTypeofName(const QString &name, IR::Expr *result);
virtual void callBuiltinTypeofValue(IR::Expr *value, IR::Expr *result);
virtual void callBuiltinDeleteMember(IR::Expr *base, const QString &name, IR::Expr *result);
virtual void callBuiltinDeleteSubscript(IR::Expr *base, IR::Expr *index, IR::Expr *result);
virtual void callBuiltinDeleteName(const QString &name, IR::Expr *result);
virtual void callBuiltinDeleteValue(IR::Expr *result);
virtual void callBuiltinThrow(IR::Expr *arg);
virtual void callBuiltinReThrow();
virtual void callBuiltinUnwindException(IR::Expr *);
virtual void callBuiltinPushCatchScope(const QString &exceptionName);
virtual void callBuiltinForeachIteratorObject(IR::Expr *arg, IR::Expr *result);
virtual void callBuiltinForeachNextPropertyname(IR::Expr *arg, IR::Expr *result);
virtual void callBuiltinPushWithScope(IR::Expr *arg);
virtual void callBuiltinPopScope();
virtual void callBuiltinDeclareVar(bool deletable, const QString &name);
virtual void callBuiltinDefineArray(IR::Expr *result, IR::ExprList *args);
virtual void callBuiltinDefineObjectLiteral(IR::Expr *result, int keyValuePairCount, IR::ExprList *keyValuePairs, IR::ExprList *arrayEntries, bool needSparseArray);
virtual void callBuiltinSetupArgumentObject(IR::Expr *result);
virtual void callBuiltinConvertThisToObject();
virtual void callValue(IR::Expr *value, IR::ExprList *args, IR::Expr *result);
virtual void callQmlContextProperty(IR::Expr *base, IR::Member::MemberKind kind, int propertyIndex, IR::ExprList *args, IR::Expr *result);
virtual void callProperty(IR::Expr *base, const QString &name, IR::ExprList *args, IR::Expr *result);
virtual void callSubscript(IR::Expr *base, IR::Expr *index, IR::ExprList *args, IR::Expr *result);
virtual void convertType(IR::Expr *source, IR::Expr *target);
virtual void loadThisObject(IR::Expr *temp);
virtual void loadQmlContext(IR::Expr *target);
virtual void loadQmlImportedScripts(IR::Expr *target);
virtual void loadQmlSingleton(const QString &name, IR::Expr *target);
virtual void loadConst(IR::Const *sourceConst, IR::Expr *target);
virtual void loadString(const QString &str, IR::Expr *target);
virtual void loadRegexp(IR::RegExp *sourceRegexp, IR::Expr *target);
virtual void getActivationProperty(const IR::Name *name, IR::Expr *target);
virtual void setActivationProperty(IR::Expr *source, const QString &targetName);
virtual void initClosure(IR::Closure *closure, IR::Expr *target);
virtual void getProperty(IR::Expr *base, const QString &name, IR::Expr *target);
virtual void getQmlContextProperty(IR::Expr *source, IR::Member::MemberKind kind, int index, bool captureRequired, IR::Expr *target);
virtual void getQObjectProperty(IR::Expr *base, int propertyIndex, bool captureRequired, bool isSingleton, int attachedPropertiesId, IR::Expr *target);
virtual void setProperty(IR::Expr *source, IR::Expr *targetBase, const QString &targetName);
virtual void setQmlContextProperty(IR::Expr *source, IR::Expr *targetBase, IR::Member::MemberKind kind, int propertyIndex);
virtual void setQObjectProperty(IR::Expr *source, IR::Expr *targetBase, int propertyIndex);
virtual void getElement(IR::Expr *base, IR::Expr *index, IR::Expr *target);
virtual void setElement(IR::Expr *source, IR::Expr *targetBase, IR::Expr *targetIndex);
virtual void copyValue(IR::Expr *source, IR::Expr *target);
virtual void swapValues(IR::Expr *source, IR::Expr *target);
virtual void unop(IR::AluOp oper, IR::Expr *sourceTemp, IR::Expr *target);
virtual void binop(IR::AluOp oper, IR::Expr *leftSource, IR::Expr *rightSource, IR::Expr *target);
void callBuiltinInvalid(IR::Name *func, IR::ExprList *args, IR::Expr *result) override;
void callBuiltinTypeofQmlContextProperty(IR::Expr *base, IR::Member::MemberKind kind, int propertyIndex, IR::Expr *result) override;
void callBuiltinTypeofMember(IR::Expr *base, const QString &name, IR::Expr *result) override;
void callBuiltinTypeofSubscript(IR::Expr *base, IR::Expr *index, IR::Expr *result) override;
void callBuiltinTypeofName(const QString &name, IR::Expr *result) override;
void callBuiltinTypeofValue(IR::Expr *value, IR::Expr *result) override;
void callBuiltinDeleteMember(IR::Expr *base, const QString &name, IR::Expr *result) override;
void callBuiltinDeleteSubscript(IR::Expr *base, IR::Expr *index, IR::Expr *result) override;
void callBuiltinDeleteName(const QString &name, IR::Expr *result) override;
void callBuiltinDeleteValue(IR::Expr *result) override;
void callBuiltinThrow(IR::Expr *arg) override;
void callBuiltinReThrow() override;
void callBuiltinUnwindException(IR::Expr *) override;
void callBuiltinPushCatchScope(const QString &exceptionName) override;
void callBuiltinForeachIteratorObject(IR::Expr *arg, IR::Expr *result) override;
void callBuiltinForeachNextPropertyname(IR::Expr *arg, IR::Expr *result) override;
void callBuiltinPushWithScope(IR::Expr *arg) override;
void callBuiltinPopScope() override;
void callBuiltinDeclareVar(bool deletable, const QString &name) override;
void callBuiltinDefineArray(IR::Expr *result, IR::ExprList *args) override;
void callBuiltinDefineObjectLiteral(IR::Expr *result, int keyValuePairCount, IR::ExprList *keyValuePairs, IR::ExprList *arrayEntries, bool needSparseArray) override;
void callBuiltinSetupArgumentObject(IR::Expr *result) override;
void callBuiltinConvertThisToObject() override;
void callValue(IR::Expr *value, IR::ExprList *args, IR::Expr *result) override;
void callQmlContextProperty(IR::Expr *base, IR::Member::MemberKind kind, int propertyIndex, IR::ExprList *args, IR::Expr *result) override;
void callProperty(IR::Expr *base, const QString &name, IR::ExprList *args, IR::Expr *result) override;
void callSubscript(IR::Expr *base, IR::Expr *index, IR::ExprList *args, IR::Expr *result) override;
void convertType(IR::Expr *source, IR::Expr *target) override;
void loadThisObject(IR::Expr *temp) override;
void loadQmlContext(IR::Expr *target) override;
void loadQmlImportedScripts(IR::Expr *target) override;
void loadQmlSingleton(const QString &name, IR::Expr *target) override;
void loadConst(IR::Const *sourceConst, IR::Expr *target) override;
void loadString(const QString &str, IR::Expr *target) override;
void loadRegexp(IR::RegExp *sourceRegexp, IR::Expr *target) override;
void getActivationProperty(const IR::Name *name, IR::Expr *target) override;
void setActivationProperty(IR::Expr *source, const QString &targetName) override;
void initClosure(IR::Closure *closure, IR::Expr *target) override;
void getProperty(IR::Expr *base, const QString &name, IR::Expr *target) override;
void getQmlContextProperty(IR::Expr *source, IR::Member::MemberKind kind, int index, bool captureRequired, IR::Expr *target) override;
void getQObjectProperty(IR::Expr *base, int propertyIndex, bool captureRequired, bool isSingleton, int attachedPropertiesId, IR::Expr *target) override;
void setProperty(IR::Expr *source, IR::Expr *targetBase, const QString &targetName) override;
void setQmlContextProperty(IR::Expr *source, IR::Expr *targetBase, IR::Member::MemberKind kind, int propertyIndex) override;
void setQObjectProperty(IR::Expr *source, IR::Expr *targetBase, int propertyIndex) override;
void getElement(IR::Expr *base, IR::Expr *index, IR::Expr *target) override;
void setElement(IR::Expr *source, IR::Expr *targetBase, IR::Expr *targetIndex) override;
void copyValue(IR::Expr *source, IR::Expr *target) override;
void swapValues(IR::Expr *source, IR::Expr *target) override;
void unop(IR::AluOp oper, IR::Expr *sourceTemp, IR::Expr *target) override;
void binop(IR::AluOp oper, IR::Expr *leftSource, IR::Expr *rightSource, IR::Expr *target) override;
typedef Assembler::Address Address;
typedef Assembler::Pointer Pointer;
@ -159,13 +159,13 @@ protected:
return _as->stackLayout().callDataAddress();
}
virtual void constructActivationProperty(IR::Name *func, IR::ExprList *args, IR::Expr *result);
virtual void constructProperty(IR::Expr *base, const QString &name, IR::ExprList *args, IR::Expr*result);
virtual void constructValue(IR::Expr *value, IR::ExprList *args, IR::Expr *result);
void constructActivationProperty(IR::Name *func, IR::ExprList *args, IR::Expr *result) override;
void constructProperty(IR::Expr *base, const QString &name, IR::ExprList *args, IR::Expr*result) override;
void constructValue(IR::Expr *value, IR::ExprList *args, IR::Expr *result) override;
virtual void visitJump(IR::Jump *);
virtual void visitCJump(IR::CJump *);
virtual void visitRet(IR::Ret *);
void visitJump(IR::Jump *) override;
void visitCJump(IR::CJump *) override;
void visitRet(IR::Ret *) override;
bool visitCJumpDouble(IR::AluOp op, IR::Expr *left, IR::Expr *right,
IR::BasicBlock *iftrue, IR::BasicBlock *iffalse);

View File

@ -253,7 +253,7 @@ class QML_PARSER_EXPORT ExpressionNode: public Node
public:
ExpressionNode() {}
virtual ExpressionNode *expressionCast();
ExpressionNode *expressionCast() override;
};
class QML_PARSER_EXPORT Statement: public Node
@ -261,7 +261,7 @@ class QML_PARSER_EXPORT Statement: public Node
public:
Statement() {}
virtual Statement *statementCast();
Statement *statementCast() override;
};
class QML_PARSER_EXPORT NestedExpression: public ExpressionNode

View File

@ -197,7 +197,7 @@ public:
{
inline ContextGuard();
inline ContextGuard &operator=(QObject *obj);
inline void objectDestroyed(QObject *);
inline void objectDestroyed(QObject *) override;
inline bool wasSet() const;

View File

@ -83,7 +83,7 @@ public:
protected:
virtual void propertyCreated(int, QMetaPropertyBuilder &);
virtual void clear();
void clear() override;
private:
QQmlOpenMetaObjectTypePrivate *d;

View File

@ -577,8 +577,8 @@ public:
void setPriority(int);
protected:
virtual void dataReceived(const Data &);
virtual void initializeFromCachedUnit(const QQmlPrivate::CachedQmlUnit*);
void dataReceived(const Data &) override;
void initializeFromCachedUnit(const QQmlPrivate::CachedQmlUnit*) override;
private:
QString m_content;

View File

@ -83,7 +83,7 @@ public:
inline QQmlVMEVariantQObjectPtr();
inline ~QQmlVMEVariantQObjectPtr();
inline void objectDestroyed(QObject *);
inline void objectDestroyed(QObject *) override;
inline void setGuardedValue(QObject *obj, QQmlVMEMetaObject *target, int index);
QQmlVMEMetaObject *m_target;

View File

@ -294,7 +294,7 @@ public:
const QVector<Compositor::Remove> &removes, const QVector<Compositor::Insert> &inserts);
void itemsChanged(const QVector<Compositor::Change> &changes);
void emitChanges();
void emitModelUpdated(const QQmlChangeSet &changeSet, bool reset);
void emitModelUpdated(const QQmlChangeSet &changeSet, bool reset) override;
bool insert(Compositor::insert_iterator &before, const QV4::Value &object, int groups);

View File

@ -143,7 +143,7 @@ public:
inline void fetchMore() { return accessors->fetchMore(*this); }
protected:
void objectDestroyed(QObject *);
void objectDestroyed(QObject *) override;
};
class QQmlAdaptorModelProxyInterface

View File

@ -78,7 +78,7 @@ protected:
QQmlEngineControlClient(QQmlEngineControlClientPrivate &dd);
private:
void messageReceived(const QByteArray &);
void messageReceived(const QByteArray &) override;
};
QT_END_NAMESPACE

View File

@ -73,7 +73,7 @@ protected:
QQmlProfilerClient(QQmlProfilerClientPrivate &dd);
private:
virtual void messageReceived(const QByteArray &message);
void messageReceived(const QByteArray &message) override;
virtual void traceStarted(qint64 time, int engineId);
virtual void traceFinished(qint64 time, int engineId);

View File

@ -77,7 +77,7 @@ class QQuickDragGrabber
QIntrusiveListNode node;
protected:
void objectDestroyed(QQuickItem *) { delete this; }
void objectDestroyed(QQuickItem *) override { delete this; }
};
typedef QIntrusiveList<Item, &Item::node> ItemList;

View File

@ -141,7 +141,7 @@ public:
virtual void update() = 0;
virtual void accept(QSGNodeVisitorEx *visitor) { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
void accept(QSGNodeVisitorEx *visitor) override { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
};
@ -165,7 +165,7 @@ public:
virtual void update() = 0;
virtual void accept(QSGNodeVisitorEx *visitor) { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
void accept(QSGNodeVisitorEx *visitor) override { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
};
class Q_QUICK_PRIVATE_EXPORT QSGPainterNode : public QSGVisitableNode
@ -188,7 +188,7 @@ public:
virtual void update() = 0;
virtual QSGTexture *texture() const = 0;
virtual void accept(QSGNodeVisitorEx *visitor) { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
void accept(QSGNodeVisitorEx *visitor) override { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
};
class Q_QUICK_EXPORT QSGLayer : public QSGDynamicTexture
@ -231,7 +231,7 @@ public:
virtual void update() = 0;
virtual void accept(QSGNodeVisitorEx *visitor) { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
void accept(QSGNodeVisitorEx *visitor) override { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
};
#endif
@ -389,7 +389,7 @@ public:
void setOwnerElement(QQuickItem *ownerElement) { m_ownerElement = ownerElement; }
QQuickItem *ownerElement() const { return m_ownerElement; }
virtual void accept(QSGNodeVisitorEx *visitor) { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
void accept(QSGNodeVisitorEx *visitor) override { if (visitor->visit(this)) visitor->visitChildren(this); visitor->endVisit(this); }
protected:
QRectF m_bounding_rect;
QQuickItem *m_ownerElement;

View File

@ -63,16 +63,16 @@ public:
QSGBasicGlyphNode();
virtual ~QSGBasicGlyphNode();
virtual QPointF baseLine() const { return m_baseLine; }
virtual void setGlyphs(const QPointF &position, const QGlyphRun &glyphs);
virtual void setColor(const QColor &color);
QPointF baseLine() const override { return m_baseLine; }
void setGlyphs(const QPointF &position, const QGlyphRun &glyphs) override;
void setColor(const QColor &color) override;
virtual void setPreferredAntialiasingMode(AntialiasingMode) { }
virtual void setStyle(QQuickText::TextStyle);
virtual void setStyleColor(const QColor &);
void setPreferredAntialiasingMode(AntialiasingMode) override { }
void setStyle(QQuickText::TextStyle) override;
void setStyleColor(const QColor &) override;
virtual void setMaterialColor(const QColor &color) = 0;
virtual void update() = 0;
void update() override = 0;
protected:
QGlyphRun m_glyphs;

View File

@ -90,10 +90,10 @@ public:
explicit QSGContextPlugin(QObject *parent = 0);
virtual ~QSGContextPlugin();
virtual QStringList keys() const = 0;
virtual QStringList keys() const override = 0;
virtual QQuickTextureFactory *createTextureFactoryFromImage(const QImage &) { return 0; }
virtual QSGRenderLoop *createWindowManager() { return 0; }
QQuickTextureFactory *createTextureFactoryFromImage(const QImage &) override { return 0; }
QSGRenderLoop *createWindowManager() override { return 0; }
};
QT_END_NAMESPACE

View File

@ -72,10 +72,10 @@ public:
QSGDefaultDistanceFieldGlyphCache(QSGDistanceFieldGlyphCacheManager *man, QOpenGLContext *c, const QRawFont &font);
virtual ~QSGDefaultDistanceFieldGlyphCache();
void requestGlyphs(const QSet<glyph_t> &glyphs);
void storeGlyphs(const QList<QDistanceField> &glyphs);
void referenceGlyphs(const QSet<glyph_t> &glyphs);
void releaseGlyphs(const QSet<glyph_t> &glyphs);
void requestGlyphs(const QSet<glyph_t> &glyphs) override;
void storeGlyphs(const QList<QDistanceField> &glyphs) override;
void referenceGlyphs(const QSet<glyph_t> &glyphs) override;
void releaseGlyphs(const QSet<glyph_t> &glyphs) override;
bool useTextureResizeWorkaround() const;
bool useTextureUploadWorkaround() const;

View File

@ -71,9 +71,9 @@ public:
QSGTextMaskMaterial(const QRawFont &font, QFontEngine::GlyphFormat glyphFormat = QFontEngine::Format_None);
virtual ~QSGTextMaskMaterial();
virtual QSGMaterialType *type() const;
virtual QSGMaterialShader *createShader() const;
virtual int compare(const QSGMaterial *other) const;
QSGMaterialType *type() const override;
QSGMaterialShader *createShader() const override;
int compare(const QSGMaterial *other) const override;
void setColor(const QColor &c) { m_color = QVector4D(c.redF(), c.greenF(), c.blueF(), c.alphaF()); }
void setColor(const QVector4D &color) { m_color = color; }
@ -115,10 +115,10 @@ public:
void setStyleColor(const QVector4D &color) { m_styleColor = color; }
const QVector4D &styleColor() const { return m_styleColor; }
virtual QSGMaterialType *type() const;
virtual QSGMaterialShader *createShader() const;
QSGMaterialType *type() const override;
QSGMaterialShader *createShader() const override;
int compare(const QSGMaterial *other) const;
int compare(const QSGMaterial *other) const override;
private:
QVector2D m_styleShift;
@ -131,8 +131,8 @@ public:
QSGOutlinedTextMaterial(const QRawFont &font);
~QSGOutlinedTextMaterial() { }
QSGMaterialType *type() const;
QSGMaterialShader *createShader() const;
QSGMaterialType *type() const override;
QSGMaterialShader *createShader() const override;
};
QT_END_NAMESPACE

View File

@ -67,19 +67,19 @@ public:
QSGDistanceFieldGlyphNode(QSGRenderContext *context);
~QSGDistanceFieldGlyphNode();
virtual QPointF baseLine() const { return m_baseLine; }
virtual void setGlyphs(const QPointF &position, const QGlyphRun &glyphs);
virtual void setColor(const QColor &color);
QPointF baseLine() const override { return m_baseLine; }
void setGlyphs(const QPointF &position, const QGlyphRun &glyphs) override;
void setColor(const QColor &color) override;
virtual void setPreferredAntialiasingMode(AntialiasingMode mode);
void setPreferredAntialiasingMode(AntialiasingMode mode) override;
virtual void setStyle(QQuickText::TextStyle style);
virtual void setStyleColor(const QColor &color);
void setStyle(QQuickText::TextStyle style) override;
void setStyleColor(const QColor &color) override;
virtual void update();
void preprocess();
void update() override;
void preprocess() override;
void invalidateGlyphs(const QVector<quint32> &glyphs);
void invalidateGlyphs(const QVector<quint32> &glyphs) override;
void updateGeometry();

View File

@ -63,9 +63,9 @@ public:
QSGDistanceFieldTextMaterial();
~QSGDistanceFieldTextMaterial();
virtual QSGMaterialType *type() const;
virtual QSGMaterialShader *createShader() const;
virtual int compare(const QSGMaterial *other) const;
QSGMaterialType *type() const override;
QSGMaterialShader *createShader() const override;
int compare(const QSGMaterial *other) const override;
virtual void setColor(const QColor &color);
const QVector4D &color() const { return m_color; }
@ -97,9 +97,9 @@ public:
QSGDistanceFieldStyledTextMaterial();
~QSGDistanceFieldStyledTextMaterial();
virtual QSGMaterialType *type() const = 0;
virtual QSGMaterialShader *createShader() const = 0;
virtual int compare(const QSGMaterial *other) const;
QSGMaterialType *type() const override = 0;
QSGMaterialShader *createShader() const override = 0;
int compare(const QSGMaterial *other) const override;
void setStyleColor(const QColor &color);
const QVector4D &styleColor() const { return m_styleColor; }
@ -114,8 +114,8 @@ public:
QSGDistanceFieldOutlineTextMaterial();
~QSGDistanceFieldOutlineTextMaterial();
virtual QSGMaterialType *type() const;
virtual QSGMaterialShader *createShader() const;
QSGMaterialType *type() const override;
QSGMaterialShader *createShader() const override;
};
class Q_QUICK_PRIVATE_EXPORT QSGDistanceFieldShiftedStyleTextMaterial : public QSGDistanceFieldStyledTextMaterial
@ -124,9 +124,9 @@ public:
QSGDistanceFieldShiftedStyleTextMaterial();
~QSGDistanceFieldShiftedStyleTextMaterial();
virtual QSGMaterialType *type() const;
virtual QSGMaterialShader *createShader() const;
virtual int compare(const QSGMaterial *other) const;
QSGMaterialType *type() const override;
QSGMaterialShader *createShader() const override;
int compare(const QSGMaterial *other) const override;
void setShift(const QPointF &shift) { m_shift = shift; }
const QPointF &shift() const { return m_shift; }
@ -138,17 +138,17 @@ protected:
class Q_QUICK_PRIVATE_EXPORT QSGHiQSubPixelDistanceFieldTextMaterial : public QSGDistanceFieldTextMaterial
{
public:
virtual QSGMaterialType *type() const;
virtual QSGMaterialShader *createShader() const;
void setColor(const QColor &color) { m_color = QVector4D(color.redF(), color.greenF(), color.blueF(), color.alphaF()); }
QSGMaterialType *type() const override;
QSGMaterialShader *createShader() const override;
void setColor(const QColor &color) override { m_color = QVector4D(color.redF(), color.greenF(), color.blueF(), color.alphaF()); }
};
class Q_QUICK_PRIVATE_EXPORT QSGLoQSubPixelDistanceFieldTextMaterial : public QSGDistanceFieldTextMaterial
{
public:
virtual QSGMaterialType *type() const;
virtual QSGMaterialShader *createShader() const;
void setColor(const QColor &color) { m_color = QVector4D(color.redF(), color.greenF(), color.blueF(), color.alphaF()); }
QSGMaterialType *type() const override;
QSGMaterialShader *createShader() const override;
void setColor(const QColor &color) override { m_color = QVector4D(color.redF(), color.greenF(), color.blueF(), color.alphaF()); }
};
QT_END_NAMESPACE

View File

@ -68,29 +68,29 @@ public:
QSGThreadedRenderLoop();
~QSGThreadedRenderLoop();
void show(QQuickWindow *) {}
void hide(QQuickWindow *);
void show(QQuickWindow *) override {}
void hide(QQuickWindow *) override;
void windowDestroyed(QQuickWindow *window);
void exposureChanged(QQuickWindow *window);
void windowDestroyed(QQuickWindow *window) override;
void exposureChanged(QQuickWindow *window) override;
QImage grab(QQuickWindow *);
QImage grab(QQuickWindow *) override;
void update(QQuickWindow *window);
void maybeUpdate(QQuickWindow *window);
void handleUpdateRequest(QQuickWindow *window);
void update(QQuickWindow *window) override;
void maybeUpdate(QQuickWindow *window) override;
void handleUpdateRequest(QQuickWindow *window) override;
QSGContext *sceneGraphContext() const;
QSGRenderContext *createRenderContext(QSGContext *) const;
QSGContext *sceneGraphContext() const override;
QSGRenderContext *createRenderContext(QSGContext *) const override;
QAnimationDriver *animationDriver() const;
QAnimationDriver *animationDriver() const override;
void releaseResources(QQuickWindow *window);
void releaseResources(QQuickWindow *window) override;
bool event(QEvent *);
void postJob(QQuickWindow *window, QRunnable *job);
bool event(QEvent *) override;
void postJob(QQuickWindow *window, QRunnable *job) override;
bool interleaveIncubation() const;
bool interleaveIncubation() const override;
public Q_SLOTS:
void animationStarted();

View File

@ -70,31 +70,31 @@ public:
explicit QSGWindowsRenderLoop();
~QSGWindowsRenderLoop();
void show(QQuickWindow *window);
void hide(QQuickWindow *window);
void show(QQuickWindow *window) override;
void hide(QQuickWindow *window) override;
void windowDestroyed(QQuickWindow *window);
void windowDestroyed(QQuickWindow *window) override;
void exposureChanged(QQuickWindow *window);
QImage grab(QQuickWindow *window);
void exposureChanged(QQuickWindow *window) override;
QImage grab(QQuickWindow *window) override;
void update(QQuickWindow *window);
void maybeUpdate(QQuickWindow *window);
void update(QQuickWindow *window) override;
void maybeUpdate(QQuickWindow *window) override;
QAnimationDriver *animationDriver() const { return m_animationDriver; }
QAnimationDriver *animationDriver() const override { return m_animationDriver; }
QSGContext *sceneGraphContext() const { return m_sg; }
QSGRenderContext *createRenderContext(QSGContext *) const;
QSGContext *sceneGraphContext() const override { return m_sg; }
QSGRenderContext *createRenderContext(QSGContext *) const override;
void releaseResources(QQuickWindow *) { }
void releaseResources(QQuickWindow *) override { }
void render();
void renderWindow(QQuickWindow *window);
bool event(QEvent *event);
bool event(QEvent *event) override;
bool anyoneShowing() const;
bool interleaveIncubation() const;
bool interleaveIncubation() const override;
public Q_SLOTS:
void started();

View File

@ -48,7 +48,7 @@ template <typename State>
class QSGSimpleMaterialShader : public QSGMaterialShader
{
public:
void initialize() {
void initialize() override {
QSGMaterialShader::initialize();
#ifndef QT_NO_OPENGL
m_id_matrix = program()->uniformLocation(uniformMatrixName());
@ -74,7 +74,7 @@ public:
const char *uniformMatrixName() const { return "qt_Matrix"; }
const char *uniformOpacityName() const { return "qt_Opacity"; }
void updateState(const RenderState &state, QSGMaterial *newMaterial, QSGMaterial *oldMaterial);
void updateState(const RenderState &state, QSGMaterial *newMaterial, QSGMaterial *oldMaterial) override;
virtual void updateState(const State *newState, const State *oldState) = 0;
@ -82,7 +82,7 @@ public:
virtual QList<QByteArray> attributes() const = 0;
char const *const *attributeNames() const
char const *const *attributeNames() const override
{
if (m_attribute_pointers.size())
return m_attribute_pointers.constData();

View File

@ -217,7 +217,7 @@ public:
setObject(static_cast<QQuickStateOperation *>(obj));
}
QList<OperationGuard> *list;
void objectDestroyed(QQuickStateOperation *) {
void objectDestroyed(QQuickStateOperation *) override {
// we assume priv will always be destroyed after objectDestroyed calls
list->removeOne(*this);
}

View File

@ -51,9 +51,9 @@ public slots:
void importData(int result);
protected:
virtual void moveEvent(QMoveEvent *event);
virtual void resizeEvent(QResizeEvent *event);
virtual void closeEvent(QCloseEvent *event);
void moveEvent(QMoveEvent *event) override;
void resizeEvent(QResizeEvent *event) override;
void closeEvent(QCloseEvent *event) override;
void initQml();
private:

View File

@ -75,12 +75,12 @@ public slots:
void setEasingCurve(const QString &code);
protected:
void paintEvent(QPaintEvent *);
void mousePressEvent(QMouseEvent *);
void mouseMoveEvent(QMouseEvent *);
void mouseReleaseEvent(QMouseEvent *);
void paintEvent(QPaintEvent *) override;
void mousePressEvent(QMouseEvent *) override;
void mouseMoveEvent(QMouseEvent *) override;
void mouseReleaseEvent(QMouseEvent *) override;
#ifndef QT_NO_CONTEXTMENU
void contextMenuEvent(QContextMenuEvent *);
void contextMenuEvent(QContextMenuEvent *) override;
#endif // QT_NO_CONTEXTMENU
void invalidate();

View File

@ -50,24 +50,24 @@ signals:
void error(const QString &error);
private:
virtual void stateChanged(State state);
void stateChanged(State state) override;
void traceStarted(qint64 time, int engineId);
void traceFinished(qint64 time, int engineId);
void rangeStart(QQmlProfilerDefinitions::RangeType type, qint64 startTime);
void rangeData(QQmlProfilerDefinitions::RangeType type, qint64 time, const QString &data);
void traceStarted(qint64 time, int engineId) override;
void traceFinished(qint64 time, int engineId) override;
void rangeStart(QQmlProfilerDefinitions::RangeType type, qint64 startTime) override;
void rangeData(QQmlProfilerDefinitions::RangeType type, qint64 time, const QString &data) override;
void rangeLocation(QQmlProfilerDefinitions::RangeType type, qint64 time,
const QQmlEventLocation &location);
void rangeEnd(QQmlProfilerDefinitions::RangeType type, qint64 endTime);
void animationFrame(qint64 time, int frameRate, int animationCount, int threadId);
const QQmlEventLocation &location) override;
void rangeEnd(QQmlProfilerDefinitions::RangeType type, qint64 endTime) override;
void animationFrame(qint64 time, int frameRate, int animationCount, int threadId) override;
void sceneGraphEvent(QQmlProfilerDefinitions::SceneGraphFrameType type, qint64 time,
qint64 numericData1, qint64 numericData2, qint64 numericData3,
qint64 numericData4, qint64 numericData5);
qint64 numericData4, qint64 numericData5) override;
void pixmapCacheEvent(QQmlProfilerDefinitions::PixmapEventType type, qint64 time,
const QString &url, int numericData1, int numericData2);
void memoryAllocation(QQmlProfilerDefinitions::MemoryType type, qint64 time, qint64 amount);
void inputEvent(QQmlProfilerDefinitions::InputEventType type, qint64 time, int a, int b);
void complete();
const QString &url, int numericData1, int numericData2) override;
void memoryAllocation(QQmlProfilerDefinitions::MemoryType type, qint64 time, qint64 amount) override;
void inputEvent(QQmlProfilerDefinitions::InputEventType type, qint64 time, int a, int b) override;
void complete() override;
};
#endif // QMLPROFILERCLIENT_H