Game info screen: Show list of any plugins that will be loaded on start of the game

This commit is contained in:
Henrik Rydgård committed 2024-04-09 12:55:50 +02:00
1 parent bab6c5997b
commit e903287f4c
5 files changed
+54 -33

No files matched your search

+11
View File
@@ -37,6 +37,7 @@
#include "Core/System.h"
#include "Core/Loaders.h"
#include "Core/Util/GameDB.h"
#include "Core/HLE/Plugins.h"
#include "UI/OnScreenDisplay.h"
#include "UI/CwCheatScreen.h"
#include "UI/EmuScreen.h"
@@ -150,6 +151,16 @@ void GameScreen::CreateViews() {
tvVerified_ = infoLayout->Add(new NoticeView(NoticeLevel::INFO, ga->T("Click \"Calculate CRC\" to verify ISO"), "", new LinearLayoutParams(FILL_PARENT, WRAP_CONTENT)));
tvVerified_->SetVisibility(UI::V_GONE);
tvVerified_->SetSquishy(true);
// Show plugin info, if any. Later might add checkboxes.
auto plugins = HLEPlugins::FindPlugins(info->id, g_Config.sLanguageIni);
if (!plugins.empty()) {
auto sy = GetI18NCategory(I18NCat::SYSTEM);
infoLayout->Add(new TextView(sy->T("Plugins"), ALIGN_LEFT, true));
for (const auto &plugin : plugins) {
infoLayout->Add(new TextView(ApplySafeSubstitutions("* %1", plugin.name), ALIGN_LEFT, true));
}
}
} else {
tvTitle_ = nullptr;
tvID_ = nullptr;