diff -r 5dc02b23752f -r 3e2da88830cd src/declarative/qml/qdeclarativeprivate.h --- a/src/declarative/qml/qdeclarativeprivate.h Tue Jul 06 15:10:48 2010 +0300 +++ b/src/declarative/qml/qdeclarativeprivate.h Wed Aug 18 10:37:55 2010 +0300 @@ -42,6 +42,17 @@ #ifndef QDECLARATIVEPRIVATE_H #define QDECLARATIVEPRIVATE_H +// +// W A R N I N G +// ------------- +// +// This file is not part of the Qt API. It exists purely as an +// implementation detail. This header file may change from version to +// version without notice, or even be removed. +// +// We mean it. +// + #include #include #ifndef Q_OS_WIN @@ -177,6 +188,9 @@ return AttachedPropertySelector::value>::value>::metaObject(); } + enum AutoParentResult { Parented, IncompatibleObject, IncompatibleParent }; + typedef AutoParentResult (*AutoParentFunction)(QObject *object, QObject *parent); + struct RegisterType { int version; @@ -214,9 +228,19 @@ const char *iid; }; - int Q_DECLARATIVE_EXPORT registerType(const RegisterType &); - int Q_DECLARATIVE_EXPORT registerType(const RegisterInterface &); + struct RegisterAutoParent { + int version; + + AutoParentFunction function; + }; + enum RegistrationType { + TypeRegistration = 0, + InterfaceRegistration = 1, + AutoParentRegistration = 2 + }; + + int Q_DECLARATIVE_EXPORT qmlregister(RegistrationType, void *); } QT_END_NAMESPACE