Tiny cleanup
authorunc0rr
Wed, 05 Oct 2011 22:57:42 +0400
changeset 6087 6e422ea250a1
parent 6086 c612f24bf162
child 6088 47d1b04003d1
Tiny cleanup
QTfrontend/mapContainer.cpp
--- a/QTfrontend/mapContainer.cpp	Wed Oct 05 10:05:14 2011 +0200
+++ b/QTfrontend/mapContainer.cpp	Wed Oct 05 22:57:42 2011 +0400
@@ -114,6 +114,8 @@
             QString scheme;
             QString weapons;
             QList<QVariant> mapInfo;
+            bool isMission = mapLuaFile.exists();
+
             QTextStream input(&mapCfgFile);
             input >> theme;
             input >> limit;
@@ -125,16 +127,22 @@
                 mapInfo.push_back(limit);
             else
                 mapInfo.push_back(18);
-            mapInfo.push_back(mapLuaFile.exists());
+
+
+            mapInfo.push_back(isMission);
+
             if (scheme.isEmpty())
                 scheme = "locked";
             scheme.replace("_", " ");
+
             if (weapons.isEmpty())
                 weapons = "locked";
             weapons.replace("_", " ");
+
             mapInfo.push_back(scheme);
             mapInfo.push_back(weapons);
-            if(mapLuaFile.exists())
+
+            if(isMission)
             {
                 chooseMap->insertItem(missionindex++, 
 // FIXME - need real icons. Disabling until then