diff options
Diffstat (limited to 'src/qml')
-rw-r--r-- | src/qml/animations/qabstractanimationjob.cpp | 2 | ||||
-rw-r--r-- | src/qml/animations/qcontinuinganimationgroupjob.cpp | 2 | ||||
-rw-r--r-- | src/qml/animations/qparallelanimationgroupjob.cpp | 2 | ||||
-rw-r--r-- | src/qml/animations/qpauseanimationjob.cpp | 2 | ||||
-rw-r--r-- | src/qml/animations/qsequentialanimationgroupjob.cpp | 2 | ||||
-rw-r--r-- | src/qml/jsruntime/qv4executablecompilationunit.cpp | 2 | ||||
-rw-r--r-- | src/qml/memory/qv4mm.cpp | 5 | ||||
-rw-r--r-- | src/qml/qml/qqmlengine.cpp | 29 | ||||
-rw-r--r-- | src/qml/qml/qqmlengine_p.h | 3 | ||||
-rw-r--r-- | src/qml/qml/qqmlvaluetype.cpp | 7 | ||||
-rw-r--r-- | src/qml/qml/qqmlvaluetype_p.h | 4 |
11 files changed, 20 insertions, 40 deletions
diff --git a/src/qml/animations/qabstractanimationjob.cpp b/src/qml/animations/qabstractanimationjob.cpp index 7a784a2b35..c6ace05b8f 100644 --- a/src/qml/animations/qabstractanimationjob.cpp +++ b/src/qml/animations/qabstractanimationjob.cpp @@ -641,7 +641,7 @@ void QAbstractAnimationJob::removeAnimationChangeListener(QAnimationJobChangeLis void QAbstractAnimationJob::debugAnimation(QDebug d) const { - d << "AbstractAnimationJob(" << hex << (const void *) this << dec << ") state:" + d << "AbstractAnimationJob(" << Qt::hex << (const void *) this << Qt::dec << ") state:" << m_state << "duration:" << duration(); } diff --git a/src/qml/animations/qcontinuinganimationgroupjob.cpp b/src/qml/animations/qcontinuinganimationgroupjob.cpp index 10096bf19c..88c0e9e60e 100644 --- a/src/qml/animations/qcontinuinganimationgroupjob.cpp +++ b/src/qml/animations/qcontinuinganimationgroupjob.cpp @@ -120,7 +120,7 @@ void QContinuingAnimationGroupJob::uncontrolledAnimationFinished(QAbstractAnimat void QContinuingAnimationGroupJob::debugAnimation(QDebug d) const { - d << "ContinuingAnimationGroupJob(" << hex << (const void *) this << dec << ")"; + d << "ContinuingAnimationGroupJob(" << Qt::hex << (const void *) this << Qt::dec << ")"; debugChildren(d); } diff --git a/src/qml/animations/qparallelanimationgroupjob.cpp b/src/qml/animations/qparallelanimationgroupjob.cpp index 700fdf9fd9..420a934ba2 100644 --- a/src/qml/animations/qparallelanimationgroupjob.cpp +++ b/src/qml/animations/qparallelanimationgroupjob.cpp @@ -239,7 +239,7 @@ void QParallelAnimationGroupJob::uncontrolledAnimationFinished(QAbstractAnimatio void QParallelAnimationGroupJob::debugAnimation(QDebug d) const { - d << "ParallelAnimationGroupJob(" << hex << (const void *) this << dec << ")"; + d << "ParallelAnimationGroupJob(" << Qt::hex << (const void *) this << Qt::dec << ")"; debugChildren(d); } diff --git a/src/qml/animations/qpauseanimationjob.cpp b/src/qml/animations/qpauseanimationjob.cpp index 0652ed578b..aac04d2f8d 100644 --- a/src/qml/animations/qpauseanimationjob.cpp +++ b/src/qml/animations/qpauseanimationjob.cpp @@ -67,7 +67,7 @@ void QPauseAnimationJob::updateCurrentTime(int) void QPauseAnimationJob::debugAnimation(QDebug d) const { - d << "PauseAnimationJob(" << hex << (const void *) this << dec << ")" << "duration:" << m_duration; + d << "PauseAnimationJob(" << Qt::hex << (const void *) this << Qt::dec << ")" << "duration:" << m_duration; } QT_END_NAMESPACE diff --git a/src/qml/animations/qsequentialanimationgroupjob.cpp b/src/qml/animations/qsequentialanimationgroupjob.cpp index d98546122f..dc57444b32 100644 --- a/src/qml/animations/qsequentialanimationgroupjob.cpp +++ b/src/qml/animations/qsequentialanimationgroupjob.cpp @@ -426,7 +426,7 @@ void QSequentialAnimationGroupJob::animationRemoved(QAbstractAnimationJob *anim, void QSequentialAnimationGroupJob::debugAnimation(QDebug d) const { - d << "SequentialAnimationGroupJob(" << hex << (const void *) this << dec << ")" << "currentAnimation:" << (void *)m_currentAnimation; + d << "SequentialAnimationGroupJob(" << Qt::hex << (const void *) this << Qt::dec << ")" << "currentAnimation:" << (void *)m_currentAnimation; debugChildren(d); } diff --git a/src/qml/jsruntime/qv4executablecompilationunit.cpp b/src/qml/jsruntime/qv4executablecompilationunit.cpp index 79e2ec2a5d..d51e986006 100644 --- a/src/qml/jsruntime/qv4executablecompilationunit.cpp +++ b/src/qml/jsruntime/qv4executablecompilationunit.cpp @@ -121,7 +121,7 @@ static QString toString(QV4::ReturnedValue v) static void dumpConstantTable(const StaticValue *constants, uint count) { QDebug d = qDebug(); - d.nospace() << right; + d.nospace() << Qt::right; for (uint i = 0; i < count; ++i) { d << qSetFieldWidth(8) << i << qSetFieldWidth(0) << ": " << toString(constants[i].asReturnedValue()).toUtf8().constData() << "\n"; diff --git a/src/qml/memory/qv4mm.cpp b/src/qml/memory/qv4mm.cpp index c7f52eac6b..3465036c86 100644 --- a/src/qml/memory/qv4mm.cpp +++ b/src/qml/memory/qv4mm.cpp @@ -223,7 +223,8 @@ Chunk *MemorySegment::allocate(size_t size) pageReservation.commit(candidate, size); for (uint i = 0; i < requiredChunks; ++i) setBit(candidate - base + i); - DEBUG << "allocated chunk " << candidate << hex << size; + DEBUG << "allocated chunk " << candidate << Qt::hex << size; + return candidate; } } @@ -1024,7 +1025,7 @@ static size_t dumpBins(BlockAllocator *b, const char *title) SDUMP() << " large slot map"; HeapItem *h = b->freeBins[BlockAllocator::NumBins - 1]; while (h) { - SDUMP() << " " << hex << (quintptr(h)/32) << h->freeData.availableSlots; + SDUMP() << " " << Qt::hex << (quintptr(h)/32) << h->freeData.availableSlots; h = h->freeData.next; } diff --git a/src/qml/qml/qqmlengine.cpp b/src/qml/qml/qqmlengine.cpp index af44d737a2..b8bd00bf2f 100644 --- a/src/qml/qml/qqmlengine.cpp +++ b/src/qml/qml/qqmlengine.cpp @@ -216,35 +216,6 @@ void QQmlEnginePrivate::defineModule() >(uri, 2); } -#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) -void QQmlEnginePrivate::registerQuickTypes() -{ - // Don't add anything here. These are only for backwards compatibility. - // Also, don't use qmlRegisterTypesAndRevisions as that will auto-add future revisions. - - const char uri[] = "QtQuick"; - - qmlRegisterType<QQmlComponent>(uri, 2, 0, "Component"); - qmlRegisterType<QObject>(uri, 2, 0, "QtObject"); - qmlRegisterType<QQmlBind>(uri, 2, 0, "Binding"); - qmlRegisterType<QQmlBind, 8>(uri, 2, 8, "Binding"); - qmlRegisterCustomType<QQmlConnections>(uri, 2, 0, "Connections", new QQmlConnectionsParser); - - // Connections revision 3 was added in QtQml 2.3, but only in QtQuick 2.7. - qmlRegisterCustomType<QQmlConnections, 3>(uri, 2, 7, "Connections", new QQmlConnectionsParser); - -#if QT_CONFIG(qml_animation) - qmlRegisterType<QQmlTimer>(uri, 2, 0,"Timer"); -#endif - qmlRegisterType<QQmlLoggingCategory>(uri, 2, 8, "LoggingCategory"); - qmlRegisterType<QQmlLoggingCategory, 12>(uri, 2, 12, "LoggingCategory"); -#if QT_CONFIG(qml_locale) - // Locale was added in QtQuick 2.0 and in QtQml 2.2 - qmlRegisterUncreatableType<QQmlLocale>(uri, 2, 0, "Locale", QQmlEngine::tr("Locale cannot be instantiated. Use Qt.locale()")); -#endif -} -#endif // QT_VERSION < QT_VERSION_CHECK(6, 0, 0) - bool QQmlEnginePrivate::designerMode() { return s_designerMode; diff --git a/src/qml/qml/qqmlengine_p.h b/src/qml/qml/qqmlengine_p.h index 5b1b676c89..98c7823921 100644 --- a/src/qml/qml/qqmlengine_p.h +++ b/src/qml/qml/qqmlengine_p.h @@ -259,9 +259,6 @@ public: static QList<QQmlError> qmlErrorFromDiagnostics(const QString &fileName, const QList<QQmlJS::DiagnosticMessage> &diagnosticMessages); static void defineModule(); -#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) - static void registerQuickTypes(); -#endif static bool designerMode(); static void activateDesignerMode(); diff --git a/src/qml/qml/qqmlvaluetype.cpp b/src/qml/qml/qqmlvaluetype.cpp index a4737b3da9..d83fc4bb48 100644 --- a/src/qml/qml/qqmlvaluetype.cpp +++ b/src/qml/qml/qqmlvaluetype.cpp @@ -130,8 +130,10 @@ const QMetaObject *QQmlValueTypeFactoryImpl::metaObjectForMetaType(int t) return &QQmlRectValueType::staticMetaObject; case QVariant::RectF: return &QQmlRectFValueType::staticMetaObject; +#if QT_CONFIG(easingcurve) case QVariant::EasingCurve: return &QQmlEasingValueType::staticMetaObject; +#endif #if QT_CONFIG(qml_itemmodel) case QVariant::ModelIndex: return &QQmlModelIndexValueType::staticMetaObject; @@ -211,7 +213,9 @@ const QMetaObject *QQmlValueTypeFactory::metaObjectForMetaType(int type) void QQmlValueTypeFactory::registerValueTypes(const char *uri, int versionMajor, int versionMinor) { +#if QT_CONFIG(easingcurve) qmlRegisterValueTypeEnums<QQmlEasingValueType>(uri, versionMajor, versionMinor, "Easing"); +#endif } QQmlValueType::QQmlValueType() : @@ -506,6 +510,7 @@ int QQmlRectValueType::bottom() const return v.bottom(); } +#if QT_CONFIG(easingcurve) QQmlEasingValueType::Type QQmlEasingValueType::type() const { return (QQmlEasingValueType::Type)v.type(); @@ -589,6 +594,8 @@ QVariantList QQmlEasingValueType::bezierCurve() const rv << QVariant(point.x()) << QVariant(point.y()); return rv; } +#endif // easingcurve + QT_END_NAMESPACE diff --git a/src/qml/qml/qqmlvaluetype_p.h b/src/qml/qml/qqmlvaluetype_p.h index 9c008859da..0601237c4b 100644 --- a/src/qml/qml/qqmlvaluetype_p.h +++ b/src/qml/qml/qqmlvaluetype_p.h @@ -58,7 +58,9 @@ #include <QtCore/qobject.h> #include <QtCore/qrect.h> +#if QT_CONFIG(easingcurve) #include <QtCore/qeasingcurve.h> +#endif #include <QtCore/qvariant.h> QT_BEGIN_NAMESPACE @@ -211,6 +213,7 @@ public: int bottom() const; }; +#if QT_CONFIG(easingcurve) struct QQmlEasingValueType { QEasingCurve v; @@ -263,6 +266,7 @@ public: void setBezierCurve(const QVariantList &); QVariantList bezierCurve() const; }; +#endif template<typename T> int qmlRegisterValueTypeEnums(const char *uri, int versionMajor, int versionMinor, const char *qmlName) |