diff options
author | Warwick Allison <warwick.allison@nokia.com> | 2010-04-08 05:25:09 (GMT) |
---|---|---|
committer | Warwick Allison <warwick.allison@nokia.com> | 2010-04-08 05:25:09 (GMT) |
commit | a563fac8c17f284bdc7499225edc674e363f6dc8 (patch) | |
tree | 95c0cb5864a7242bed0ab7cc0b77994c7d4e7b5e /src/declarative/qml/qdeclarativeobjectscriptclass.cpp | |
parent | 23ca795df373ef41d2b3020c9ea7c38714aaa67b (diff) | |
parent | cabf4f41a51599b3527cd848af14966986430566 (diff) | |
download | Qt-a563fac8c17f284bdc7499225edc674e363f6dc8.zip Qt-a563fac8c17f284bdc7499225edc674e363f6dc8.tar.gz Qt-a563fac8c17f284bdc7499225edc674e363f6dc8.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7
Diffstat (limited to 'src/declarative/qml/qdeclarativeobjectscriptclass.cpp')
-rw-r--r-- | src/declarative/qml/qdeclarativeobjectscriptclass.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/declarative/qml/qdeclarativeobjectscriptclass.cpp b/src/declarative/qml/qdeclarativeobjectscriptclass.cpp index 10b9fab..32ba2c3 100644 --- a/src/declarative/qml/qdeclarativeobjectscriptclass.cpp +++ b/src/declarative/qml/qdeclarativeobjectscriptclass.cpp @@ -100,6 +100,9 @@ QScriptValue QDeclarativeObjectScriptClass::newQObject(QObject *object, int type if (!object) return newObject(scriptEngine, this, new ObjectData(object, type)); + if (QObjectPrivate::get(object)->wasDeleted) + return scriptEngine->undefinedValue(); + QDeclarativeDeclarativeData *ddata = QDeclarativeDeclarativeData::get(object, true); if (!ddata) { |