A fix for the "continuing game" feature.
authorMarja Hassinen <marja2@Vahvero.(none)>
Sun, 3 Jan 2010 19:18:52 +0000 (21:18 +0200)
committerMarja Hassinen <marja2@Vahvero.(none)>
Sun, 3 Jan 2010 19:18:52 +0000 (21:18 +0200)
src/game.cpp

index bd9b0b9..7c9f829 100644 (file)
@@ -588,7 +588,7 @@ void LevelSwitcher::chooseLevelCollection()
             total = levelCollections[collection].size();
         }
 
-        newItem->setText(collection + " " + 
+        newItem->setText(collection + "   \tPassed: " + 
                          QString::number(passed) + " / " + QString::number(total));
         levelList->addItem(newItem); // transfers ownership
         if (first && passed < total) {
@@ -706,7 +706,8 @@ void LevelSwitcher::readSavedGames()
         saveData >> collection;
         saveData >> level;
         qDebug() << "Got saved game: " << collection << level;
-        savedGames.insert(collection, level);
+        if (collection != "")
+            savedGames.insert(collection, level);
     }
     file.close();
 }