summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinQt/TAS/TASInputWindow.cpp
diff options
context:
space:
mode:
authorspycrab <spycrab@users.noreply.github.com>2019-04-03 18:43:11 +0200
committerGitHub <noreply@github.com>2019-04-03 18:43:11 +0200
commit923151e3e3aeb5caa3f76fc51ea0d10bb1c4a0f7 (patch)
treee1db6379ea181a034863b7f37dcaddcff95a74c6 /Source/Core/DolphinQt/TAS/TASInputWindow.cpp
parent741a975ac27d35f98926d1adafd13b0cbdea1a91 (diff)
parent039b1baa3a20441c136ac115098f69374a1ead13 (diff)
Merge pull request #7949 from spycrab/turbo_btn
Qt/TAS: Implement turbo mode
Diffstat (limited to 'Source/Core/DolphinQt/TAS/TASInputWindow.cpp')
-rw-r--r--Source/Core/DolphinQt/TAS/TASInputWindow.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/Source/Core/DolphinQt/TAS/TASInputWindow.cpp b/Source/Core/DolphinQt/TAS/TASInputWindow.cpp
index e87f358889..a559ae887c 100644
--- a/Source/Core/DolphinQt/TAS/TASInputWindow.cpp
+++ b/Source/Core/DolphinQt/TAS/TASInputWindow.cpp
@@ -18,6 +18,7 @@
#include "DolphinQt/QtUtils/AspectRatioWidget.h"
#include "DolphinQt/QtUtils/QueueOnObject.h"
#include "DolphinQt/TAS/StickWidget.h"
+#include "DolphinQt/TAS/TASCheckBox.h"
#include "DolphinQt/TAS/TASInputWindow.h"
#include "InputCommon/GCPadStatus.h"
@@ -130,7 +131,7 @@ QSpinBox* TASInputWindow::CreateSliderValuePair(QBoxLayout* layout, u16 max,
}
template <typename UX>
-void TASInputWindow::GetButton(QCheckBox* checkbox, UX& buttons, UX mask)
+void TASInputWindow::GetButton(TASCheckBox* checkbox, UX& buttons, UX mask)
{
const bool pressed = (buttons & mask) != 0;
if (m_use_controller->isChecked())
@@ -147,13 +148,13 @@ void TASInputWindow::GetButton(QCheckBox* checkbox, UX& buttons, UX mask)
}
}
- if (checkbox->isChecked())
+ if (checkbox->GetValue())
buttons |= mask;
else
buttons &= ~mask;
}
-template void TASInputWindow::GetButton<u8>(QCheckBox* button, u8& pad, u8 mask);
-template void TASInputWindow::GetButton<u16>(QCheckBox* button, u16& pad, u16 mask);
+template void TASInputWindow::GetButton<u8>(TASCheckBox* button, u8& pad, u8 mask);
+template void TASInputWindow::GetButton<u16>(TASCheckBox* button, u16& pad, u16 mask);
void TASInputWindow::GetSpinBoxU8(QSpinBox* spin, u8& controller_value)
{