Minor change to Qt GUI window focus audio mute logic. Ensure that it is always re-computed on a window active change event.

This commit is contained in:
harry 2023-01-11 21:08:55 -05:00
parent 739c01f051
commit cc1e6a8f8b
1 changed files with 4 additions and 2 deletions

View File

@ -435,6 +435,7 @@ void consoleWin_t::winScreenChanged(QScreen *scr)
void consoleWin_t::winActiveChanged(void)
{
QWidget *w;
bool muteWindow = false;
w = this->window();
@ -450,15 +451,16 @@ void consoleWin_t::winActiveChanged(void)
{
if ( hdl->isActive() )
{
FCEUD_MuteSoundWindow(false);
muteWindow = false;
}
else
{
FCEUD_MuteSoundWindow(true);
muteWindow = true;
}
}
}
}
FCEUD_MuteSoundWindow(muteWindow);
}
QSize consoleWin_t::calcRequiredSize(void)