QTfrontend/hwform.cpp
changeset 1223 41d7283934c1
parent 1165 40eeae82e70b
child 1225 f882a92ef872
--- a/QTfrontend/hwform.cpp	Sat Aug 16 13:29:18 2008 +0000
+++ b/QTfrontend/hwform.cpp	Sat Aug 16 14:28:44 2008 +0000
@@ -54,6 +54,8 @@
 	UpdateTeamsLists();
 	UpdateWeapons();
 
+	StartMusic();
+
 	connect(config, SIGNAL(frontendFullscreen(bool)), this, SLOT(onFrontendFullscreen(bool)));
 	onFrontendFullscreen(config->isFrontendFullscreen());
 
@@ -544,6 +546,8 @@
 {
 	switch(gameState) {
 		case gsStarted: {
+			StopMusic();
+			GoToPage(ID_PAGE_INGAME);
 			ui.pageGameStats->labelGameStats->setText("");
 			if (pRegisterServer)
 			{
@@ -554,6 +558,7 @@
 		}
 		case gsFinished: {
 			GoBack();
+			StartMusic();
 			GoToPage(ID_PAGE_GAMESTATS);
 			break;
 		}
@@ -612,8 +617,6 @@
 	connect(game, SIGNAL(GameStats(char, const QString &)), this, SLOT(GameStats(char, const QString &)));
 	connect(game, SIGNAL(ErrorMessage(const QString &)), this, SLOT(ShowErrorMessage(const QString &)), Qt::QueuedConnection);
 	connect(game, SIGNAL(HaveRecord(bool, const QByteArray &)), this, SLOT(GetRecord(bool, const QByteArray &)));
-
-	GoToPage(ID_PAGE_INGAME);
 }
 
 void HWForm::ShowErrorMessage(const QString & msg)
@@ -679,3 +682,13 @@
 	config->SaveOptions();
 	event->accept();
 }
+
+void HWForm::StartMusic()
+{
+
+}
+
+void HWForm::StopMusic()
+{
+
+}