InfinityBaseWindow: Collapse lambda into direct member pointer

The parameters to this match the requirements of the toggled() function
exactly, so we can pass the function directly into the connect call.
This commit is contained in:
Lioncash 2023-06-08 10:55:27 -04:00
parent 1f874be36e
commit d092381d25
1 changed files with 1 additions and 1 deletions

View File

@ -55,7 +55,7 @@ void InfinityBaseWindow::CreateMainWindow()
checkbox_layout->setAlignment(Qt::AlignHCenter);
m_checkbox = new QCheckBox(tr("Emulate Infinity Base"), this);
m_checkbox->setChecked(Config::Get(Config::MAIN_EMULATE_INFINITY_BASE));
connect(m_checkbox, &QCheckBox::toggled, [=](bool checked) { EmulateBase(checked); });
connect(m_checkbox, &QCheckBox::toggled, this, &InfinityBaseWindow::EmulateBase);
checkbox_layout->addWidget(m_checkbox);
checkbox_group->setLayout(checkbox_layout);
main_layout->addWidget(checkbox_group);