mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-05-21 18:42:38 +00:00
InputCommon/ControllerEmu: Break out functionality of EmulatedController
to eliminate redundant unused members in Wii Remote extension objects.
This commit is contained in:
parent
225039f742
commit
ddb82a5e8c
26 changed files with 312 additions and 245 deletions
|
@ -17,11 +17,8 @@
|
|||
#include <QSpinBox>
|
||||
#include <QVBoxLayout>
|
||||
|
||||
#include "Common/CommonTypes.h"
|
||||
|
||||
#include "DolphinQt/Host.h"
|
||||
#include "DolphinQt/QtUtils/AspectRatioWidget.h"
|
||||
#include "DolphinQt/QtUtils/QueueOnObject.h"
|
||||
#include "DolphinQt/Resources.h"
|
||||
#include "DolphinQt/TAS/StickWidget.h"
|
||||
#include "DolphinQt/TAS/TASCheckBox.h"
|
||||
|
@ -250,14 +247,12 @@ std::optional<ControlState> TASInputWindow::GetButton(TASCheckBox* checkbox,
|
|||
std::optional<ControlState> TASInputWindow::GetSpinBox(TASSpinBox* spin, int zero, int min, int max,
|
||||
ControlState controller_state)
|
||||
{
|
||||
const int controller_value =
|
||||
ControllerEmu::EmulatedController::MapFloat<int>(controller_state, zero, 0, max);
|
||||
const int controller_value = ControllerEmu::MapFloat<int>(controller_state, zero, 0, max);
|
||||
|
||||
if (m_use_controller->isChecked())
|
||||
spin->OnControllerValueChanged(controller_value);
|
||||
|
||||
return ControllerEmu::EmulatedController::MapToFloat<ControlState, int>(spin->GetValue(), zero,
|
||||
min, max);
|
||||
return ControllerEmu::MapToFloat<ControlState, int>(spin->GetValue(), zero, min, max);
|
||||
}
|
||||
|
||||
std::optional<ControlState> TASInputWindow::GetSpinBox(TASSpinBox* spin, int zero,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue