summaryrefslogtreecommitdiffstats
path: root/PySide/QtDeclarative/pysideqmlregistertype.cpp
diff options
context:
space:
mode:
authorHugo Parente Lima <hugo.pl@gmail.com>2010-12-08 15:15:29 -0200
committerHugo Parente Lima <hugo.pl@gmail.com>2010-12-09 14:40:57 -0200
commit1422aed61669e0d1710f0da19ba57c58a613f397 (patch)
treefe4e61cafff20373cb3dcc188f75af1bf2519c8c /PySide/QtDeclarative/pysideqmlregistertype.cpp
parent1464dc1022ad5afca0cea9c86b28b35eaf2c634b (diff)
downloadpyside-1422aed61669e0d1710f0da19ba57c58a613f397.tar.gz
pyside-1422aed61669e0d1710f0da19ba57c58a613f397.tar.xz
pyside-1422aed61669e0d1710f0da19ba57c58a613f397.zip
Replace useless check by a assert.
QMetaObject must already be ready at this point.
Diffstat (limited to 'PySide/QtDeclarative/pysideqmlregistertype.cpp')
-rw-r--r--PySide/QtDeclarative/pysideqmlregistertype.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/PySide/QtDeclarative/pysideqmlregistertype.cpp b/PySide/QtDeclarative/pysideqmlregistertype.cpp
index e15379b..5a51706 100644
--- a/PySide/QtDeclarative/pysideqmlregistertype.cpp
+++ b/PySide/QtDeclarative/pysideqmlregistertype.cpp
@@ -105,10 +105,7 @@ int PySide::qmlRegisterType(PyObject* pyObj, const char* uri, int versionMajor,
}
QMetaObject* metaObject = reinterpret_cast<QMetaObject*>(ObjectType::getTypeUserData(reinterpret_cast<SbkObjectType*>(pyObj)));
- if (!metaObject) {
- PyErr_SetString(PyExc_TypeError, "FIXME: metaobject not initialized, this error msg should not exists at all!!");
- return -1;
- }
+ Q_ASSERT(metaObject);
// All ready... now the ugly code begins... :-)
pyTypes[nextType] = pyObj;