summaryrefslogtreecommitdiffstats
path: root/src/declarative/qml
diff options
context:
space:
mode:
authorKai Koehne <kai.koehne@nokia.com>2009-05-18 10:35:36 (GMT)
committerKai Koehne <kai.koehne@nokia.com>2009-05-18 10:46:05 (GMT)
commit72516886fffdc0d66592655d47f1a869f89472f7 (patch)
tree0ffb61523a523b135c1c7924064dd485aaaeefe3 /src/declarative/qml
parent6e5d9637b981e532ef9c92d88aa88a4388d69384 (diff)
downloadQt-72516886fffdc0d66592655d47f1a869f89472f7.zip
Qt-72516886fffdc0d66592655d47f1a869f89472f7.tar.gz
Qt-72516886fffdc0d66592655d47f1a869f89472f7.tar.bz2
Do not store empty type names in QmlMetaType
Diffstat (limited to 'src/declarative/qml')
-rw-r--r--src/declarative/qml/qmlmetatype.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/declarative/qml/qmlmetatype.cpp b/src/declarative/qml/qmlmetatype.cpp
index df61a82..2e490a4 100644
--- a/src/declarative/qml/qmlmetatype.cpp
+++ b/src/declarative/qml/qmlmetatype.cpp
@@ -388,7 +388,8 @@ int QmlMetaType::registerInterface(const QmlPrivate::MetaTypeIds &id,
data->idToType.insert(type->typeId(), type);
data->idToType.insert(type->qListTypeId(), type);
data->idToType.insert(type->qmlListTypeId(), type);
- data->nameToType.insert(type->qmlTypeName(), type);
+ if (!type->qmlTypeName().isEmpty())
+ data->nameToType.insert(type->qmlTypeName(), type);
if (data->interfaces.size() < id.typeId)
data->interfaces.resize(id.typeId + 16);