QTfrontend/mapContainer.cpp
changeset 1210 bfed1b89bc85
parent 1209 7f6cb1d7be2a
child 1211 94c4f20abdda
--- a/QTfrontend/mapContainer.cpp	Thu Aug 14 13:34:44 2008 +0000
+++ b/QTfrontend/mapContainer.cpp	Thu Aug 14 14:04:45 2008 +0000
@@ -53,13 +53,8 @@
 
   chooseMap = new QComboBox(this);
   chooseMap->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed);
-  QDir tmpdir;
-  tmpdir.cd(datadir->absolutePath());
-  tmpdir.cd("Maps");
-  tmpdir.setFilter(QDir::Dirs | QDir::NoDotAndDotDot);
-  QStringList mapList=tmpdir.entryList(QStringList("*"));
-  mapList.push_front(QComboBox::tr("generated map..."));
-  chooseMap->addItems(mapList);
+  chooseMap->addItem(QComboBox::tr("generated map..."));
+  chooseMap->addItems(*mapList);
   connect(chooseMap, SIGNAL(activated(int)), this, SLOT(mapChanged(int)));
   mainLayout.addWidget(chooseMap, 1, 1);
 
@@ -70,9 +65,14 @@
 	gbThemes->setTitle(tr("Themes"));
 	gbThemes->setStyleSheet("padding: 0px;");
 	mainLayout.addWidget(gbThemes, 0, 2, 2, 1);
+	
 	QVBoxLayout * gbTLayout = new QVBoxLayout(gbThemes);
 	lwThemes = new QListWidget(this);
+	lwThemes->setMinimumHeight(30);
 	lwThemes->setFixedWidth(100);
+	for (int i = 0; i < Themes->size(); ++i)
+		lwThemes->addItem(Themes->at(i));
+	
 	gbTLayout->addWidget(lwThemes);
 	lwThemes->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Minimum);