QTfrontend/ui/page/pagetraining.cpp
changeset 6930 d187ea93fc4f
parent 6700 e04da46ee43c
child 6952 7f70f37bbf08
equal deleted inserted replaced
6929:c305d31642ac 6930:d187ea93fc4f
    26 #include <QFile>
    26 #include <QFile>
    27 #include <QLocale>
    27 #include <QLocale>
    28 #include <QSettings>
    28 #include <QSettings>
    29 
    29 
    30 #include "hwconsts.h"
    30 #include "hwconsts.h"
    31 #include "HWDataManager.h"
    31 #include "DataManager.h"
    32 
    32 
    33 #include "pagetraining.h"
    33 #include "pagetraining.h"
    34 
    34 
    35 QLayout * PageTraining::bodyLayoutDefinition()
    35 QLayout * PageTraining::bodyLayoutDefinition()
    36 {
    36 {
   113 
   113 
   114 PageTraining::PageTraining(QWidget* parent) : AbstractPage(parent)
   114 PageTraining::PageTraining(QWidget* parent) : AbstractPage(parent)
   115 {
   115 {
   116     initPage();
   116     initPage();
   117 
   117 
   118     HWDataManager & dataMgr = HWDataManager::instance();
   118     DataManager & dataMgr = DataManager::instance();
   119 
   119 
   120     // get locale
   120     // get locale
   121     QSettings settings(cfgdir->absolutePath() + "/hedgewars.ini",
   121     QSettings settings(cfgdir->absolutePath() + "/hedgewars.ini",
   122                        QSettings::IniFormat);
   122                        QSettings::IniFormat);
   123 
   123 
   184 }
   184 }
   185 
   185 
   186 
   186 
   187 void PageTraining::updateInfo()
   187 void PageTraining::updateInfo()
   188 {
   188 {
   189     HWDataManager & dataMgr = HWDataManager::instance();
   189     DataManager & dataMgr = DataManager::instance();
   190 
   190 
   191     if (lstMissions->currentItem())
   191     if (lstMissions->currentItem())
   192     {
   192     {
   193         // TODO also use .pngs in userdata folder
   193         // TODO also use .pngs in userdata folder
   194         QString thumbFile = dataMgr.findFileForRead(
   194         QString thumbFile = dataMgr.findFileForRead(