mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-03-29 13:20:35 +00:00
Loosen mode restrictions on opening Journal window (Fixes #1570)
This commit is contained in:
parent
cd8287da16
commit
ef78ae22f6
@ -805,16 +805,16 @@ namespace MWInput
|
|||||||
if (MyGUI::InputManager::getInstance ().isModalAny())
|
if (MyGUI::InputManager::getInstance ().isModalAny())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if((!MWBase::Environment::get().getWindowManager()->isGuiMode()
|
if(MWBase::Environment::get().getWindowManager()->getMode() != MWGui::GM_Journal
|
||||||
|| MWBase::Environment::get().getWindowManager()->getMode() == MWGui::GM_Dialogue)
|
&& MWBase::Environment::get().getWindowManager ()->getJournalAllowed()
|
||||||
&& MWBase::Environment::get().getWindowManager ()->getJournalAllowed())
|
&& MWBase::Environment::get().getWindowManager()->getMode() != MWGui::GM_Console)
|
||||||
{
|
{
|
||||||
MWBase::Environment::get().getSoundManager()->playSound ("book open", 1.0, 1.0);
|
MWBase::Environment::get().getSoundManager()->playSound ("book open", 1.0, 1.0);
|
||||||
MWBase::Environment::get().getWindowManager()->pushGuiMode(MWGui::GM_Journal);
|
MWBase::Environment::get().getWindowManager()->pushGuiMode(MWGui::GM_Journal);
|
||||||
}
|
}
|
||||||
else if(MWBase::Environment::get().getWindowManager()->getMode() == MWGui::GM_Journal)
|
else if(MWBase::Environment::get().getWindowManager()->containsMode(MWGui::GM_Journal))
|
||||||
{
|
{
|
||||||
MWBase::Environment::get().getWindowManager()->exitCurrentGuiMode();
|
MWBase::Environment::get().getWindowManager()->removeGuiMode(MWGui::GM_Journal);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user