refactor: ActionDialog, make buttonbox connections in c++

This commit is contained in:
sithlord48 2025-01-04 19:58:58 -05:00 committed by Nick Bolton
parent c36c0f2938
commit 4e913a90eb
2 changed files with 2 additions and 32 deletions

View File

@ -36,6 +36,8 @@ ActionDialog::ActionDialog(QWidget *parent, const ServerConfig &config, Hotkey &
{
ui->setupUi(this);
connect(ui->keySequenceWidget, &KeySequenceWidget::keySequenceChanged, this, &ActionDialog::keySequenceChanged);
connect(ui->buttonBox, &QDialogButtonBox::accepted, this, &ActionDialog::accept);
connect(ui->buttonBox, &QDialogButtonBox::rejected, this, &ActionDialog::reject);
// work around Qt Designer's lack of a QButtonGroup; we need it to get
// at the button id of the checked radio button

View File

@ -310,38 +310,6 @@
</customwidgets>
<resources/>
<connections>
<connection>
<sender>buttonBox</sender>
<signal>accepted()</signal>
<receiver>ActionDialog</receiver>
<slot>accept()</slot>
<hints>
<hint type="sourcelabel">
<x>245</x>
<y>474</y>
</hint>
<hint type="destinationlabel">
<x>157</x>
<y>274</y>
</hint>
</hints>
</connection>
<connection>
<sender>buttonBox</sender>
<signal>rejected()</signal>
<receiver>ActionDialog</receiver>
<slot>reject()</slot>
<hints>
<hint type="sourcelabel">
<x>313</x>
<y>474</y>
</hint>
<hint type="destinationlabel">
<x>286</x>
<y>274</y>
</hint>
</hints>
</connection>
<connection>
<sender>m_pGroupType</sender>
<signal>toggled(bool)</signal>