From b493bdb912b49b39dc92baf58ea6904fa1322618 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Sun, 26 Jan 2020 21:41:28 -0500 Subject: [PATCH] DolphinQt/TASCheckBox: Mark GetValue() as const This doesn't actually modify the checkbox's state, so this can be marked as a const-qualified member function. --- Source/Core/DolphinQt/TAS/TASCheckBox.cpp | 2 +- Source/Core/DolphinQt/TAS/TASCheckBox.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/Core/DolphinQt/TAS/TASCheckBox.cpp b/Source/Core/DolphinQt/TAS/TASCheckBox.cpp index 9f4d34514e..917309b860 100644 --- a/Source/Core/DolphinQt/TAS/TASCheckBox.cpp +++ b/Source/Core/DolphinQt/TAS/TASCheckBox.cpp @@ -13,7 +13,7 @@ TASCheckBox::TASCheckBox(const QString& text) : QCheckBox(text) setTristate(true); } -bool TASCheckBox::GetValue() +bool TASCheckBox::GetValue() const { if (checkState() == Qt::PartiallyChecked) return Movie::GetCurrentFrame() % 2 == static_cast(m_trigger_on_odd); diff --git a/Source/Core/DolphinQt/TAS/TASCheckBox.h b/Source/Core/DolphinQt/TAS/TASCheckBox.h index a39cd446bf..4e02e45b46 100644 --- a/Source/Core/DolphinQt/TAS/TASCheckBox.h +++ b/Source/Core/DolphinQt/TAS/TASCheckBox.h @@ -14,7 +14,7 @@ class TASCheckBox : public QCheckBox public: explicit TASCheckBox(const QString& text); - bool GetValue(); + bool GetValue() const; protected: void mousePressEvent(QMouseEvent* event) override;