| 16 | #include <QtWidgets/QFileDialog> |
| 17 | |
| 18 | BIOSSettingsWidget::BIOSSettingsWidget(SettingsWindow* settings_dialog, QWidget* parent) |
| 19 | : SettingsWidget(settings_dialog, parent) |
| 20 | { |
| 21 | SettingsInterface* sif = dialog()->getSettingsInterface(); |
| 22 | |
| 23 | setupTab(m_ui); |
| 24 | |
| 25 | SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.fastBoot, "EmuCore", "EnableFastBoot", true); |
| 26 | SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.fastBootFastForward, "EmuCore", "EnableFastBootFastForward", false); |
| 27 | SettingWidgetBinder::BindWidgetToFolderSetting(sif, m_ui.searchDirectory, m_ui.browseSearchDirectory, m_ui.openSearchDirectory, |
| 28 | m_ui.resetSearchDirectory, "Folders", "Bios", Path::Combine(EmuFolders::DataRoot, "bios")); |
| 29 | |
| 30 | dialog()->registerWidgetHelp(m_ui.fastBoot, tr("Fast Boot"), tr("Checked"), |
| 31 | tr("Patches the BIOS to skip the console's boot animation.")); |
| 32 | |
| 33 | dialog()->registerWidgetHelp(m_ui.fastBootFastForward, tr("Fast Forward Boot"), tr("Unchecked"), |
| 34 | tr("Removes emulation speed throttle until the game starts to reduce startup time.")); |
| 35 | |
| 36 | refreshList(); |
| 37 | |
| 38 | connect(m_ui.searchDirectory, &QLineEdit::textChanged, this, &BIOSSettingsWidget::refreshList); |
| 39 | connect(m_ui.refresh, &QPushButton::clicked, this, &BIOSSettingsWidget::refreshList); |
| 40 | connect(m_ui.fileList, &QTreeWidget::currentItemChanged, this, &BIOSSettingsWidget::listItemChanged); |
| 41 | connect(m_ui.fastBoot, &QCheckBox::checkStateChanged, this, &BIOSSettingsWidget::fastBootChanged); |
| 42 | |
| 43 | fastBootChanged(); |
| 44 | } |
| 45 | |
| 46 | BIOSSettingsWidget::~BIOSSettingsWidget() = default; |
| 47 |
nothing calls this directly
no test coverage detected