equal
deleted
inserted
replaced
919 QString randomSeed = tr("Randomize the seed"); |
919 QString randomSeed = tr("Randomize the seed"); |
920 QString randomAllPrev = tr("Click to randomize the map, theme and seed"); |
920 QString randomAllPrev = tr("Click to randomize the map, theme and seed"); |
921 QString randomNoMapPrev = tr("Click to randomize the theme and seed"); |
921 QString randomNoMapPrev = tr("Click to randomize the theme and seed"); |
922 QString mfsComplex = QString(tr("Adjust the complexity of the generated map")); |
922 QString mfsComplex = QString(tr("Adjust the complexity of the generated map")); |
923 QString mfsFortsDistance = QString(tr("Adjust the distance between forts")); |
923 QString mfsFortsDistance = QString(tr("Adjust the distance between forts")); |
|
924 QString mfsDrawnMap = QString(tr("Scale size of the drawn map")); |
924 switch (type) |
925 switch (type) |
925 { |
926 { |
926 case MapModel::GeneratedMap: |
927 case MapModel::GeneratedMap: |
927 case MapModel::GeneratedPerlin: |
928 case MapModel::GeneratedPerlin: |
928 case MapModel::GeneratedMaze: |
929 case MapModel::GeneratedMaze: |
936 btnRandomize->setWhatsThis(randomAll); |
937 btnRandomize->setWhatsThis(randomAll); |
937 break; |
938 break; |
938 case MapModel::HandDrawnMap: |
939 case MapModel::HandDrawnMap: |
939 mapPreview->setWhatsThis(tr("Click to edit")); |
940 mapPreview->setWhatsThis(tr("Click to edit")); |
940 btnRandomize->setWhatsThis(randomSeed); |
941 btnRandomize->setWhatsThis(randomSeed); |
|
942 mapFeatureSize->setWhatsThis(mfsDrawnMap); |
941 break; |
943 break; |
942 case MapModel::FortsMap: |
944 case MapModel::FortsMap: |
943 mapPreview->setWhatsThis(randomNoMapPrev); |
945 mapPreview->setWhatsThis(randomNoMapPrev); |
944 mapFeatureSize->setWhatsThis(mfsFortsDistance); |
946 mapFeatureSize->setWhatsThis(mfsFortsDistance); |
945 btnRandomize->setWhatsThis(randomNoMap); |
947 btnRandomize->setWhatsThis(randomNoMap); |
988 break; |
990 break; |
989 case MapModel::HandDrawnMap: |
991 case MapModel::HandDrawnMap: |
990 mapgen = MAPGEN_DRAWN; |
992 mapgen = MAPGEN_DRAWN; |
991 setMapInfo(MapModel::MapInfoDrawn); |
993 setMapInfo(MapModel::MapInfoDrawn); |
992 btnLoadMap->show(); |
994 btnLoadMap->show(); |
993 mapFeatureSize->hide(); |
995 //mapFeatureSize->hide(); |
994 btnEditMap->show(); |
996 btnEditMap->show(); |
995 break; |
997 break; |
996 case MapModel::MissionMap: |
998 case MapModel::MissionMap: |
997 setupMissionMapsView(); |
999 setupMissionMapsView(); |
998 mapgen = MAPGEN_MAP; |
1000 mapgen = MAPGEN_MAP; |
1073 intSetFeatureSize(val); |
1075 intSetFeatureSize(val); |
1074 //m_mapFeatureSize = val>>2<<2; |
1076 //m_mapFeatureSize = val>>2<<2; |
1075 //if (qAbs(m_prevMapFeatureSize-m_mapFeatureSize) > 4) |
1077 //if (qAbs(m_prevMapFeatureSize-m_mapFeatureSize) > 4) |
1076 { |
1078 { |
1077 m_prevMapFeatureSize = m_mapFeatureSize; |
1079 m_prevMapFeatureSize = m_mapFeatureSize; |
1078 updatePreview(); |
1080 if(m_mapInfo.type!= MapModel::HandDrawnMap) |
|
1081 updatePreview(); |
1079 } |
1082 } |
1080 } |
1083 } |
1081 |
1084 |
1082 // unused because I needed the space for the slider |
1085 // unused because I needed the space for the slider |
1083 void HWMapContainer::updateThemeButtonSize() |
1086 void HWMapContainer::updateThemeButtonSize() |
1084 { |
1087 { |
1085 if (m_mapInfo.type != MapModel::StaticMap && m_mapInfo.type != MapModel::HandDrawnMap) |
1088 if (m_mapInfo.type != MapModel::StaticMap) |
1086 { |
1089 { |
1087 btnTheme->setIconSize(QSize(30, 30)); |
1090 btnTheme->setIconSize(QSize(30, 30)); |
1088 btnTheme->setFixedHeight(30); |
1091 btnTheme->setFixedHeight(30); |
1089 btnRandTheme->setFixedHeight(30); |
1092 btnRandTheme->setFixedHeight(30); |
1090 btnRandTheme->setIconSize(QSize(24, 24)); |
1093 btnRandTheme->setIconSize(QSize(24, 24)); |