mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-15 22:49:48 +00:00
Merge branch 'settingswindow' into 'master'
Hide the settings window when any main menu button is pressed See merge request OpenMW/openmw!4136
This commit is contained in:
commit
05815b3952
@ -100,10 +100,6 @@ namespace MWGui
|
|||||||
{
|
{
|
||||||
winMgr->removeGuiMode(GM_MainMenu);
|
winMgr->removeGuiMode(GM_MainMenu);
|
||||||
}
|
}
|
||||||
else if (name == "options")
|
|
||||||
{
|
|
||||||
winMgr->toggleSettingsWindow();
|
|
||||||
}
|
|
||||||
else if (name == "credits")
|
else if (name == "credits")
|
||||||
winMgr->playVideo("mw_credits.bik", true);
|
winMgr->playVideo("mw_credits.bik", true);
|
||||||
else if (name == "exitgame")
|
else if (name == "exitgame")
|
||||||
@ -132,17 +128,18 @@ namespace MWGui
|
|||||||
dialog->eventCancelClicked.clear();
|
dialog->eventCancelClicked.clear();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (name == "loadgame" || name == "savegame")
|
||||||
else
|
|
||||||
{
|
{
|
||||||
if (!mSaveGameDialog)
|
if (!mSaveGameDialog)
|
||||||
mSaveGameDialog = std::make_unique<SaveGameDialog>();
|
mSaveGameDialog = std::make_unique<SaveGameDialog>();
|
||||||
if (name == "loadgame")
|
mSaveGameDialog->setLoadOrSave(name == "loadgame");
|
||||||
mSaveGameDialog->setLoadOrSave(true);
|
|
||||||
else if (name == "savegame")
|
|
||||||
mSaveGameDialog->setLoadOrSave(false);
|
|
||||||
mSaveGameDialog->setVisible(true);
|
mSaveGameDialog->setVisible(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (winMgr->isSettingsWindowVisible() || name == "options")
|
||||||
|
{
|
||||||
|
winMgr->toggleSettingsWindow();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainMenu::showBackground(bool show)
|
void MainMenu::showBackground(bool show)
|
||||||
|
Loading…
Reference in New Issue
Block a user