1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2026-02-07 18:28:25 +00:00

Merge branch 'updatespellwindowquickkey' into 'master'

Update spell window after selecting spell using quickkey #8436

See merge request OpenMW/openmw!4611
This commit is contained in:
psi29a 2025-07-01 21:29:30 +00:00
commit 48bc9e5dd2

View file

@ -421,6 +421,9 @@ namespace MWGui
}
store.setSelectedEnchantItem(it);
// to reset WindowManager::mSelectedSpell immediately
MWBase::Environment::get().getWindowManager()->setSelectedEnchantItem(*it);
MWBase::Environment::get().getWorld()->getPlayer().setDrawState(MWMechanics::DrawState::Spell);
}
}
@ -448,6 +451,9 @@ namespace MWGui
store.unequipSlot(MWWorld::InventoryStore::Slot_CarriedRight);
MWBase::Environment::get().getWorld()->getPlayer().setDrawState(MWMechanics::DrawState::Weapon);
}
// Updates the state of equipped/not equipped (skin) in spellwindow
MWBase::Environment::get().getWindowManager()->updateSpellWindow();
}
// ---------------------------------------------------------------------------------------------------------