QTfrontend/ui/widget/mapContainer.cpp
changeset 13261 0cfa8f6a4e80
parent 13260 7f8f2c77a9cc
child 13263 66dd7b5f7d33
equal deleted inserted replaced
13260:7f8f2c77a9cc 13261:0cfa8f6a4e80
  1227     {
  1227     {
  1228         teMapName->setHidden(master);
  1228         teMapName->setHidden(master);
  1229         missionMapList->setVisible(master);
  1229         missionMapList->setVisible(master);
  1230     }
  1230     }
  1231 
  1231 
  1232     if(m_missingMap)
  1232     if(master)
  1233     {
  1233     {
  1234         // Force map type reset if host provided missing map
  1234         // Room delegation cleanup if we get room control.
  1235         m_missingMap = false;
  1235 
  1236         changeMapType(MapModel::GeneratedMap);
  1236         if(m_missingMap)
       
  1237         {
       
  1238             // Force map type and theme reset we don't have the map
       
  1239             m_missingMap = false;
       
  1240             changeMapType(MapModel::GeneratedMap);
       
  1241             setRandomTheme();
       
  1242         }
       
  1243         else
       
  1244         {
       
  1245             // Set random theme if we don't have it
       
  1246             QModelIndexList mdl = m_themeModel->match(m_themeModel->index(0), ThemeModel::ActualNameRole, m_theme);
       
  1247             if(!mdl.size())
       
  1248                 setRandomTheme();
       
  1249         }
  1237     }
  1250     }
  1238 }
  1251 }
  1239 
  1252 
  1240 void HWMapContainer::setMissingTheme(const QString & name)
  1253 void HWMapContainer::setMissingTheme(const QString & name)
  1241 {
  1254 {