Qt: Fix default button in ControllerLEDSettingsDialog

This commit is contained in:
Davide Pesavento 2025-06-21 16:25:06 -04:00
parent 467e2c6c97
commit 1d68d9121b
3 changed files with 4 additions and 10 deletions

View File

@ -139,7 +139,6 @@
</widget>
<resources>
<include location="resources/duckstation-qt.qrc"/>
<include location="resources/duckstation-qt.qrc"/>
</resources>
<connections/>
</ui>

View File

@ -126,6 +126,7 @@ ControllerLEDSettingsDialog::ControllerLEDSettingsDialog(QWidget* parent, Contro
: QDialog(parent), m_dialog(dialog)
{
m_ui.setupUi(this);
m_ui.buttonBox->button(QDialogButtonBox::Close)->setDefault(true);
linkButton(m_ui.SDL0LED, 0);
linkButton(m_ui.SDL1LED, 1);

View File

@ -6,8 +6,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>501</width>
<height>108</height>
<width>500</width>
<height>118</height>
</rect>
</property>
<property name="windowTitle">
@ -62,14 +62,8 @@
</layout>
</widget>
</item>
<item row="1" column="2" colspan="2">
<item row="1" column="0" colspan="4">
<widget class="QDialogButtonBox" name="buttonBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="standardButtons">
<set>QDialogButtonBox::StandardButton::Close</set>
</property>