diff --git a/RetroFE/Source/Execute/Launcher.cpp b/RetroFE/Source/Execute/Launcher.cpp index 60140f7..2176418 100644 --- a/RetroFE/Source/Execute/Launcher.cpp +++ b/RetroFE/Source/Execute/Launcher.cpp @@ -122,7 +122,10 @@ bool Launcher::run(std::string collection, Item *collectionItem) return false; } - return true; + bool reboot = false; + config_.getProperty("launchers." + launcherName + ".reboot", reboot); + + return reboot; } std::string Launcher::replaceVariables(std::string str, diff --git a/RetroFE/Source/RetroFE.cpp b/RetroFE/Source/RetroFE.cpp index b2cd03b..fd3267e 100644 --- a/RetroFE/Source/RetroFE.cpp +++ b/RetroFE/Source/RetroFE.cpp @@ -1036,10 +1036,18 @@ bool RetroFE::run( ) if (currentPage_->getPlaylistName( ) != attractModeSkipPlaylist && nextPageItem_->collectionInfo->name != lastPlayedSkipCollection) cib.updateLastPlayedPlaylist( currentPage_->getCollection(), nextPageItem_, size ); // Update last played playlist if not currently in the skip playlist (e.g. settings) - l.run(nextPageItem_->collectionInfo->name, nextPageItem_); - launchExit( ); - currentPage_->exitGame( ); - state = RETROFE_LAUNCH_EXIT; + if (l.run(nextPageItem_->collectionInfo->name, nextPageItem_)) // Run and check if we need to reboot + { + attract_.reset( ); + reboot_ = true; + state = RETROFE_QUIT_REQUEST; + } + else + { + launchExit( ); + currentPage_->exitGame( ); + state = RETROFE_LAUNCH_EXIT; + } } break; @@ -1707,9 +1715,9 @@ CollectionInfo *RetroFE::getCollection(std::string collectionName) (void)config_.getProperty( "showParenthesis", showParenthesis ); (void)config_.getProperty( "showSquareBrackets", showSquareBrackets ); - typedef std::map *> Playlists_T; - for ( Playlists_T::iterator itP = collection->playlists.begin( ); itP != collection->playlists.end( ); itP++ ) - { + typedef std::map *> Playlists_T; + for ( Playlists_T::iterator itP = collection->playlists.begin( ); itP != collection->playlists.end( ); itP++ ) + { for ( std::vector ::iterator itI = itP->second->begin( ); itI != itP->second->end( ); itI++ ) { if ( !showParenthesis ) diff --git a/RetroFE/Source/Version.cpp b/RetroFE/Source/Version.cpp index d973095..9cef966 100644 --- a/RetroFE/Source/Version.cpp +++ b/RetroFE/Source/Version.cpp @@ -21,7 +21,7 @@ std::string retrofe_version_major = "0"; std::string retrofe_version_minor = "9"; -std::string retrofe_version_build = "36"; +std::string retrofe_version_build = "37"; std::string Version::getString( )