Build fix for systems without Qt QML installed.

This commit is contained in:
harry 2024-01-15 20:09:25 -05:00
parent 198cdafbf8
commit 9a9f9541d6
1 changed files with 4 additions and 0 deletions

View File

@ -1478,6 +1478,7 @@ int fceuWrapperUpdate( void )
if ( GameInfo )
{
#ifdef __FCEU_QSCRIPT_ENABLE__
auto* qscriptMgr = QtScriptManager::getInstance();
bool scriptsLoaded = (qscriptMgr != nullptr) && (qscriptMgr->numScriptsLoaded() > 0);
@ -1486,13 +1487,16 @@ int fceuWrapperUpdate( void )
{
qscriptMgr->frameBeginUpdate();
}
#endif
DoFun(frameskip, periodic_saves);
#ifdef __FCEU_QSCRIPT_ENABLE__
if (scriptsLoaded)
{
qscriptMgr->frameFinishedUpdate();
}
#endif
hexEditorUpdateMemoryValues();