summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinQt2/Config/ControllersWindow.cpp
diff options
context:
space:
mode:
authorJosJuice <josjuice@gmail.com>2018-04-17 22:40:11 +0200
committerJosJuice <josjuice@gmail.com>2018-04-17 22:40:21 +0200
commit2953cf201dc5f00ca79f1c16cbd62136097ff77f (patch)
treeff0cdf93580816a80af7dd7cf984479cc291aeed /Source/Core/DolphinQt2/Config/ControllersWindow.cpp
parentdfd6a228a69021ca88daaee2de457871f77f8c77 (diff)
Remove Hybrid Wii Remote
It simply doesn't seem to work for anything useful, and nobody seems to care about maintaining it.
Diffstat (limited to 'Source/Core/DolphinQt2/Config/ControllersWindow.cpp')
-rw-r--r--Source/Core/DolphinQt2/Config/ControllersWindow.cpp27
1 files changed, 3 insertions, 24 deletions
diff --git a/Source/Core/DolphinQt2/Config/ControllersWindow.cpp b/Source/Core/DolphinQt2/Config/ControllersWindow.cpp
index cb62e6e50d..ad94caa1a2 100644
--- a/Source/Core/DolphinQt2/Config/ControllersWindow.cpp
+++ b/Source/Core/DolphinQt2/Config/ControllersWindow.cpp
@@ -42,9 +42,6 @@ static const std::map<SerialInterface::SIDevices, int> s_gc_types = {
{SerialInterface::SIDEVICE_DANCEMAT, 4}, {SerialInterface::SIDEVICE_GC_TARUKONGA, 5},
{SerialInterface::SIDEVICE_GC_GBA, 6}, {SerialInterface::SIDEVICE_GC_KEYBOARD, 7}};
-static const std::map<int, int> s_wiimote_types = {
- {WIIMOTE_SRC_NONE, 0}, {WIIMOTE_SRC_EMU, 1}, {WIIMOTE_SRC_REAL, 2}, {WIIMOTE_SRC_HYBRID, 3}};
-
static int ToGCMenuIndex(const SerialInterface::SIDevices sidevice)
{
return s_gc_types.at(sidevice);
@@ -57,18 +54,6 @@ static SerialInterface::SIDevices FromGCMenuIndex(const int menudevice)
return it->first;
}
-static int ToWiimoteMenuIndex(const int device)
-{
- return s_wiimote_types.at(device);
-}
-
-static int FromWiimoteMenuIndex(const int menudevice)
-{
- auto it = std::find_if(s_wiimote_types.begin(), s_wiimote_types.end(),
- [=](auto pair) { return pair.second == menudevice; });
- return it->first;
-}
-
ControllersWindow::ControllersWindow(QWidget* parent) : QDialog(parent)
{
setWindowTitle(tr("Controller Settings"));
@@ -189,11 +174,8 @@ void ControllersWindow::CreateWiimoteLayout()
auto* wm_box = m_wiimote_boxes[i] = new QComboBox();
auto* wm_button = m_wiimote_buttons[i] = new QPushButton(tr("Configure"));
- for (const auto& item :
- {tr("None"), tr("Emulated Wii Remote"), tr("Real Wii Remote"), tr("Hybrid Wii Remote")})
- {
+ for (const auto& item : {tr("None"), tr("Emulated Wii Remote"), tr("Real Wii Remote")})
wm_box->addItem(item);
- }
int wm_row = m_wiimote_layout->rowCount();
m_wiimote_layout->addWidget(wm_label, wm_row, 1);
@@ -458,9 +440,6 @@ void ControllersWindow::OnWiimoteConfigure()
case 1: // Emulated Wii Remote
type = MappingWindow::Type::MAPPING_WIIMOTE_EMU;
break;
- case 3: // Hybrid Wii Remote
- type = MappingWindow::Type::MAPPING_WIIMOTE_HYBRID;
- break;
default:
return;
}
@@ -482,7 +461,7 @@ void ControllersWindow::LoadSettings()
for (size_t i = 0; i < m_wiimote_groups.size(); i++)
{
m_gc_controller_boxes[i]->setCurrentIndex(ToGCMenuIndex(SConfig::GetInstance().m_SIDevice[i]));
- m_wiimote_boxes[i]->setCurrentIndex(ToWiimoteMenuIndex(g_wiimote_sources[i]));
+ m_wiimote_boxes[i]->setCurrentIndex(g_wiimote_sources[i]);
}
m_wiimote_real_balance_board->setChecked(g_wiimote_sources[WIIMOTE_BALANCE_BOARD] ==
WIIMOTE_SRC_REAL);
@@ -513,7 +492,7 @@ void ControllersWindow::SaveSettings()
for (size_t i = 0; i < m_wiimote_groups.size(); i++)
{
const int index = m_wiimote_boxes[i]->currentIndex();
- g_wiimote_sources[i] = FromWiimoteMenuIndex(index);
+ g_wiimote_sources[i] = index;
m_wiimote_buttons[i]->setEnabled(index != 0 && index != 2);
}