summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/widgets/tabs/setup_joystick.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/widgets/tabs/setup_joystick.cpp b/src/gui/widgets/tabs/setup_joystick.cpp
index 8215390de..ab623b901 100644
--- a/src/gui/widgets/tabs/setup_joystick.cpp
+++ b/src/gui/widgets/tabs/setup_joystick.cpp
@@ -123,12 +123,12 @@ void Setup_Joystick::action(const ActionEvent &event)
}
else if (source == mDetectButton)
{
+ Joystick::detect();
+ Joystick::getNames(mNamesModel->getNames());
if (joystick != nullptr)
- {
- joystick->reload();
- Joystick::getNames(mNamesModel->getNames());
mNamesDropDown->setSelected(joystick->getNumber());
- }
+ else
+ mNamesDropDown->setSelected(0);
}
else
{