1
0
Fork 0
forked from suyu/suyu

Allow NRO files to skip FW and keys' presence checks (#11)

doing an old suggestion from the now-deleted "emulator-suggestions" channel on the discord
Co-authored-by: nullequal <nullequal@noreply.localhost>
Co-committed-by: nullequal <nullequal@noreply.localhost>
This commit is contained in:
null 2024-03-23 16:31:28 +01:00 committed by Exverge
parent 18ba0f1345
commit 15ca12c0ec

View file

@ -1747,6 +1747,8 @@ void GMainWindow::AllowOSSleep() {
} }
bool GMainWindow::LoadROM(const QString& filename, Service::AM::FrontendAppletParameters params) { bool GMainWindow::LoadROM(const QString& filename, Service::AM::FrontendAppletParameters params) {
if (Loader::IdentifyType(Core::GetGameFileFromPath(vfs, filename.toStdString())) !=
Loader::FileType::NRO) {
if (!CheckFirmwarePresence()) { if (!CheckFirmwarePresence()) {
QMessageBox::critical(this, tr("Component Missing"), tr("Missing Firmware.")); QMessageBox::critical(this, tr("Component Missing"), tr("Missing Firmware."));
return false; return false;
@ -1760,6 +1762,7 @@ bool GMainWindow::LoadROM(const QString& filename, Service::AM::FrontendAppletPa
"in order to play them.")); "in order to play them."));
return false; return false;
} }
}
// Shutdown previous session if the emu thread is still active... // Shutdown previous session if the emu thread is still active...
if (emu_thread != nullptr) { if (emu_thread != nullptr) {