void QDeclarativeUtilModule::defineModule() { qmlRegisterUncreatableType<QDeclarativeApplication>("QtQuick",2,0,"Application", QDeclarativeApplication::tr("Application is an abstract class")); qmlRegisterUncreatableType<QDeclarativeAbstractAnimation>("QtQuick",2,0,"Animation",QDeclarativeAbstractAnimation::tr("Animation is an abstract class")); qmlRegisterType<QDeclarativeBehavior>("QtQuick",2,0,"Behavior"); qmlRegisterType<QDeclarativeBind>("QtQuick",2,0,"Binding"); qmlRegisterType<QDeclarativeColorAnimation>("QtQuick",2,0,"ColorAnimation"); qmlRegisterType<QDeclarativeConnections>("QtQuick",2,0,"Connections"); qmlRegisterType<QDeclarativeSmoothedAnimation>("QtQuick",2,0,"SmoothedAnimation"); qmlRegisterType<QDeclarativeFontLoader>("QtQuick",2,0,"FontLoader"); qmlRegisterType<QDeclarativeNumberAnimation>("QtQuick",2,0,"NumberAnimation"); qmlRegisterType<QDeclarativePackage>("QtQuick",2,0,"Package"); qmlRegisterType<QDeclarativeParallelAnimation>("QtQuick",2,0,"ParallelAnimation"); qmlRegisterType<QDeclarativePauseAnimation>("QtQuick",2,0,"PauseAnimation"); qmlRegisterType<QDeclarativePropertyAction>("QtQuick",2,0,"PropertyAction"); qmlRegisterType<QDeclarativePropertyAnimation>("QtQuick",2,0,"PropertyAnimation"); qmlRegisterType<QDeclarativeRotationAnimation>("QtQuick",2,0,"RotationAnimation"); qmlRegisterType<QDeclarativeScriptAction>("QtQuick",2,0,"ScriptAction"); qmlRegisterType<QDeclarativeSequentialAnimation>("QtQuick",2,0,"SequentialAnimation"); qmlRegisterType<QDeclarativeSpringAnimation>("QtQuick",2,0,"SpringAnimation"); qmlRegisterType<QDeclarativeStateChangeScript>("QtQuick",2,0,"StateChangeScript"); qmlRegisterType<QDeclarativeStateGroup>("QtQuick",2,0,"StateGroup"); qmlRegisterType<QDeclarativeState>("QtQuick",2,0,"State"); qmlRegisterType<QDeclarativeSystemPalette>("QtQuick",2,0,"SystemPalette"); qmlRegisterType<QDeclarativeTimer>("QtQuick",2,0,"Timer"); qmlRegisterType<QDeclarativeTransition>("QtQuick",2,0,"Transition"); qmlRegisterType<QDeclarativeVector3dAnimation>("QtQuick",2,0,"Vector3dAnimation"); #ifdef QT_NO_XMLPATTERNS qmlRegisterTypeNotAvailable("QtQuick",2,0,"XmlListModel", qApp->translate("QDeclarativeXmlListModel","Qt was built without support for xmlpatterns")); qmlRegisterTypeNotAvailable("QtQuick",2,0,"XmlRole", qApp->translate("QDeclarativeXmlListModel","Qt was built without support for xmlpatterns")); #else qmlRegisterType<QDeclarativeXmlListModel>("QtQuick",2,0,"XmlListModel"); qmlRegisterType<QDeclarativeXmlListModelRole>("QtQuick",2,0,"XmlRole"); #endif qmlRegisterType<QDeclarativeStateOperation>(); qmlRegisterCustomType<QDeclarativePropertyChanges>("QtQuick",2,0,"PropertyChanges", new QDeclarativePropertyChangesParser); qmlRegisterCustomType<QDeclarativeConnections>("QtQuick",2,0,"Connections", new QDeclarativeConnectionsParser); registerBaseTypes("QtQuick",2,0); }
void TypeSystem::clearStatus() { types.clear(); classMap.clear(); registerBaseTypes(); }
TypeSystem::TypeSystem() : types(), ptrTypeMap(), arrTypeMap(), basictypes(makeBasicTypes()) { // register all base types registerBaseTypes(); }