This commit is contained in:
Max-Wilhelm Bruker 2009-11-30 19:33:45 +01:00
parent 55482246dd
commit 59e9416f57
29 changed files with 332 additions and 187 deletions

View file

@ -56,16 +56,12 @@ void SerializableItem_Map::readElement(QXmlStreamReader *xml)
else if (xml->isStartElement()) {
QString childName = xml->name().toString();
QString childSubType = xml->attributes().value("type").toString();
qDebug() << "Map: started new item, name=" << childName << "subtype=" << childSubType;
currentItem = itemMap.value(childName);
if (!currentItem) {
qDebug() << "Item not found in map";
currentItem = getNewItem(childName + childSubType);
itemList.append(currentItem);
if (!currentItem) {
qDebug() << "Item still not found";
if (!currentItem)
currentItem = new SerializableItem_Invalid(childName);
}
}
if (currentItem->read(xml))
currentItem = 0;