Răsfoiți Sursa

Removed unused STOP_CLIENT SDL event

AlexVinS 9 ani în urmă
părinte
comite
1c9dd41188
3 a modificat fișierele cu 2 adăugiri și 11 ștergeri
  1. 0 3
      client/CMT.cpp
  2. 0 5
      client/CPlayerInterface.cpp
  3. 2 3
      client/CPlayerInterface.h

+ 0 - 3
client/CMT.cpp

@@ -1150,9 +1150,6 @@ static void handleEvent(SDL_Event & ev)
 				GH.defActionsDef = 63;
 			}
 			break;
-		case STOP_CLIENT:
-			client->endGame(false);
-			break;
 		case RESTART_GAME:
 			{
 				StartInfo si = *client->getStartInfo(true);

+ 0 - 5
client/CPlayerInterface.cpp

@@ -2463,11 +2463,6 @@ void CPlayerInterface::requestReturningToMainMenu()
 	cb->unregisterAllInterfaces();
 }
 
-void CPlayerInterface::requestStoppingClient()
-{
-	sendCustomEvent(STOP_CLIENT);
-}
-
 void CPlayerInterface::sendCustomEvent( int code )
 {
 	CGuiHandler::pushSDLEvent(SDL_USEREVENT, code);

+ 2 - 3
client/CPlayerInterface.h

@@ -74,8 +74,8 @@ enum
 {
 	/*CHANGE_SCREEN_RESOLUTION = 1,*/
 	RETURN_TO_MAIN_MENU = 2,
-	STOP_CLIENT = 3,
-	RESTART_GAME,
+	//STOP_CLIENT = 3,
+	RESTART_GAME = 4,
 	RETURN_TO_MENU_LOAD,
 	FULLSCREEN_TOGGLED,
 	PREPARE_RESTART_CAMPAIGN,
@@ -260,7 +260,6 @@ public:
 	void tryDiggging(const CGHeroInstance *h);
 	void showShipyardDialogOrProblemPopup(const IShipyard *obj); //obj may be town or shipyard;
 	void requestReturningToMainMenu();
-	void requestStoppingClient();
 	void sendCustomEvent(int code);
 	void proposeLoadingGame();