QTfrontend/hwform.cpp
changeset 11973 1de4d6b35748
parent 11964 3c15903256a7
child 11983 4a2da00bbedc
equal deleted inserted replaced
11972:7dd85fe00de3 11973:1de4d6b35748
   316     pageSwitchMapper->setMapping(ui.pageSinglePlayer->BtnMultiplayer, ID_PAGE_MULTIPLAYER);
   316     pageSwitchMapper->setMapping(ui.pageSinglePlayer->BtnMultiplayer, ID_PAGE_MULTIPLAYER);
   317 
   317 
   318     connect(ui.pageSinglePlayer->BtnLoad, SIGNAL(clicked()), this, SLOT(GoToSaves()));
   318     connect(ui.pageSinglePlayer->BtnLoad, SIGNAL(clicked()), this, SLOT(GoToSaves()));
   319     connect(ui.pageSinglePlayer->BtnDemos, SIGNAL(clicked()), this, SLOT(GoToDemos()));
   319     connect(ui.pageSinglePlayer->BtnDemos, SIGNAL(clicked()), this, SLOT(GoToDemos()));
   320 
   320 
   321     connect(ui.pageTraining, SIGNAL(startMission(const QString&)), this, SLOT(startTraining(const QString&)));
   321     connect(ui.pageTraining, SIGNAL(startMission(const QString&, const QString&)), this, SLOT(startTraining(const QString&, const QString&)));
   322 
   322 
   323     connect(ui.pageCampaign->BtnStartCampaign, SIGNAL(clicked()), this, SLOT(StartCampaign()));
   323     connect(ui.pageCampaign->BtnStartCampaign, SIGNAL(clicked()), this, SLOT(StartCampaign()));
   324     connect(ui.pageCampaign->btnPreview, SIGNAL(clicked()), this, SLOT(StartCampaign()));
   324     connect(ui.pageCampaign->btnPreview, SIGNAL(clicked()), this, SLOT(StartCampaign()));
   325     connect(ui.pageCampaign->CBTeam, SIGNAL(currentIndexChanged(int)), this, SLOT(UpdateCampaignPage(int)));
   325     connect(ui.pageCampaign->CBTeam, SIGNAL(currentIndexChanged(int)), this, SLOT(UpdateCampaignPage(int)));
   326     connect(ui.pageCampaign->CBTeam, SIGNAL(currentIndexChanged(int)), this, SLOT(UpdateCampaignPageTeam(int)));
   326     connect(ui.pageCampaign->CBTeam, SIGNAL(currentIndexChanged(int)), this, SLOT(UpdateCampaignPageTeam(int)));
  1699     }
  1699     }
  1700 
  1700 
  1701     ui.pageVideos->startEncoding(record);
  1701     ui.pageVideos->startEncoding(record);
  1702 }
  1702 }
  1703 
  1703 
  1704 void HWForm::startTraining(const QString & scriptName)
  1704 void HWForm::startTraining(const QString & scriptName, const QString & subFolder)
  1705 {
  1705 {
  1706     CreateGame(0, 0, 0);
  1706     CreateGame(0, 0, 0);
  1707 
  1707 
  1708     game->StartTraining(scriptName);
  1708     game->StartTraining(scriptName, subFolder);
  1709 }
  1709 }
  1710 
  1710 
  1711 void HWForm::StartCampaign()
  1711 void HWForm::StartCampaign()
  1712 {
  1712 {
  1713     CreateGame(0, 0, 0);
  1713     CreateGame(0, 0, 0);
  2093 
  2093 
  2094     CreateGame(lastGameCfg, lastGameTeamSel, lastGameAmmo);
  2094     CreateGame(lastGameCfg, lastGameTeamSel, lastGameAmmo);
  2095 
  2095 
  2096     switch(lastGameType) {
  2096     switch(lastGameType) {
  2097     case gtTraining:
  2097     case gtTraining:
  2098         game->StartTraining(lastGameStartArgs.at(0).toString());
  2098         game->StartTraining(lastGameStartArgs.at(0).toString(), lastTrainingSubFolder);
  2099         break;
  2099         break;
  2100     case gtQLocal:
  2100     case gtQLocal:
  2101         game->StartQuick();
  2101         game->StartQuick();
  2102         break;
  2102         break;
  2103     case gtCampaign:
  2103     case gtCampaign: