Merge pull request #12425 from Naim2000/no-install-wad

Disable installing WADs and importing/exporting Wii saves while emulation is running
This commit is contained in:
Admiral H. Curtiss 2023-12-16 05:09:26 +01:00 committed by GitHub
commit 1daaaf8c26
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 2 deletions

View File

@ -296,8 +296,10 @@ void MenuBar::AddToolsMenu()
tools_menu->addSeparator(); tools_menu->addSeparator();
tools_menu->addAction(tr("Import Wii Save..."), this, &MenuBar::ImportWiiSave); m_import_wii_save =
tools_menu->addAction(tr("Export All Wii Saves"), this, &MenuBar::ExportWiiSaves); tools_menu->addAction(tr("Import Wii Save..."), this, &MenuBar::ImportWiiSave);
m_export_wii_saves =
tools_menu->addAction(tr("Export All Wii Saves"), this, &MenuBar::ExportWiiSaves);
QMenu* menu = new QMenu(tr("Connect Wii Remotes"), tools_menu); QMenu* menu = new QMenu(tr("Connect Wii Remotes"), tools_menu);
@ -1021,8 +1023,11 @@ void MenuBar::UpdateToolsMenu(bool emulation_started)
m_ntscj_ipl->setEnabled(!emulation_started && File::Exists(Config::GetBootROMPath(JAP_DIR))); m_ntscj_ipl->setEnabled(!emulation_started && File::Exists(Config::GetBootROMPath(JAP_DIR)));
m_ntscu_ipl->setEnabled(!emulation_started && File::Exists(Config::GetBootROMPath(USA_DIR))); m_ntscu_ipl->setEnabled(!emulation_started && File::Exists(Config::GetBootROMPath(USA_DIR)));
m_pal_ipl->setEnabled(!emulation_started && File::Exists(Config::GetBootROMPath(EUR_DIR))); m_pal_ipl->setEnabled(!emulation_started && File::Exists(Config::GetBootROMPath(EUR_DIR)));
m_wad_install_action->setEnabled(!emulation_started);
m_import_backup->setEnabled(!emulation_started); m_import_backup->setEnabled(!emulation_started);
m_check_nand->setEnabled(!emulation_started); m_check_nand->setEnabled(!emulation_started);
m_import_wii_save->setEnabled(!emulation_started);
m_export_wii_saves->setEnabled(!emulation_started);
if (!emulation_started) if (!emulation_started)
{ {

View File

@ -213,6 +213,8 @@ private:
QAction* m_check_nand; QAction* m_check_nand;
QAction* m_extract_certificates; QAction* m_extract_certificates;
std::array<QAction*, 5> m_wii_remotes; std::array<QAction*, 5> m_wii_remotes;
QAction* m_import_wii_save;
QAction* m_export_wii_saves;
// Emulation // Emulation
QAction* m_play_action; QAction* m_play_action;