void MainMenu::optionsBackButtonClicked(Button* ) { getConfig()->save(); if( getConfig()->videoX != SDL_GetVideoSurface()->w || getConfig()->videoY != SDL_GetVideoSurface()->h) { if( getConfig()->restartOnChangeScreen ) { quitState = RESTART; running = false; } else { //SDL_IGNORE to avoid forth and back jumping resolution SDL_EventState(SDL_VIDEORESIZE, SDL_IGNORE); initVideo( getConfig()->videoX, getConfig()->videoY); currentMenu->resize(getConfig()->videoX, getConfig()->videoY); SDL_EventState(SDL_VIDEORESIZE, SDL_ENABLE); gotoMainMenu(); } } else if( currentLanguage != getConfig()->language ) { unsetenv("LINCITY_LANG"); quitState = RESTART; running = false; } else { gotoMainMenu(); } }
void PlayManager::init() { gotoMainMenu(); }
void QTitleBar::slotBtnHomeIsClicked() { emit gotoMainMenu(); }