QTfrontend/ui/widget/mapContainer.cpp
changeset 11754 2e4f0d0fec99
parent 11753 5c192a4751d8
child 11757 6874644a2d00
equal deleted inserted replaced
11753:5c192a4751d8 11754:2e4f0d0fec99
   525     emit seedChanged(m_seed);
   525     emit seedChanged(m_seed);
   526 }
   526 }
   527 
   527 
   528 void HWMapContainer::setRandomTheme()
   528 void HWMapContainer::setRandomTheme()
   529 {
   529 {
   530     QAbstractItemModel * tmodel = m_themeModel->withoutDLC();
   530     if(!m_themeModel->rowCount()) return;
   531     if(!tmodel->rowCount()) return;
   531     quint32 themeNum = rand() % m_themeModel->rowCount();
   532     quint32 themeNum = rand() % tmodel->rowCount();
   532     updateTheme(m_themeModel->index(themeNum));
   533     updateTheme(tmodel->index(themeNum,0));
       
   534     emit themeChanged(m_theme);
   533     emit themeChanged(m_theme);
   535 }
   534 }
   536 
   535 
   537 void HWMapContainer::intSetTemplateFilter(int filter)
   536 void HWMapContainer::intSetTemplateFilter(int filter)
   538 {
   537 {