mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-26 18:35:20 +00:00
Restore the previous key focus widget after playing video
This commit is contained in:
parent
f5d90f7d98
commit
9897400d97
@ -1743,6 +1743,7 @@ namespace MWGui
|
|||||||
MyGUI::IntSize screenSize = MyGUI::RenderManager::getInstance().getViewSize();
|
MyGUI::IntSize screenSize = MyGUI::RenderManager::getInstance().getViewSize();
|
||||||
sizeVideo(screenSize.width, screenSize.height);
|
sizeVideo(screenSize.width, screenSize.height);
|
||||||
|
|
||||||
|
MyGUI::Widget* oldKeyFocus = MyGUI::InputManager::getInstance().getKeyFocusWidget();
|
||||||
setKeyFocusWidget(mVideoWidget);
|
setKeyFocusWidget(mVideoWidget);
|
||||||
|
|
||||||
mVideoBackground->setVisible(true);
|
mVideoBackground->setVisible(true);
|
||||||
@ -1770,6 +1771,8 @@ namespace MWGui
|
|||||||
|
|
||||||
MWBase::Environment::get().getSoundManager()->resumeSounds();
|
MWBase::Environment::get().getSoundManager()->resumeSounds();
|
||||||
|
|
||||||
|
setKeyFocusWidget(oldKeyFocus);
|
||||||
|
|
||||||
setCursorVisible(cursorWasVisible);
|
setCursorVisible(cursorWasVisible);
|
||||||
|
|
||||||
// Restore normal rendering
|
// Restore normal rendering
|
||||||
|
Loading…
x
Reference in New Issue
Block a user