mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-10 08:09:26 +01:00
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.
This commit is contained in:
parent
42c03c4dad
commit
b493bdb912
@ -13,7 +13,7 @@ TASCheckBox::TASCheckBox(const QString& text) : QCheckBox(text)
|
|||||||
setTristate(true);
|
setTristate(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool TASCheckBox::GetValue()
|
bool TASCheckBox::GetValue() const
|
||||||
{
|
{
|
||||||
if (checkState() == Qt::PartiallyChecked)
|
if (checkState() == Qt::PartiallyChecked)
|
||||||
return Movie::GetCurrentFrame() % 2 == static_cast<u64>(m_trigger_on_odd);
|
return Movie::GetCurrentFrame() % 2 == static_cast<u64>(m_trigger_on_odd);
|
||||||
|
@ -14,7 +14,7 @@ class TASCheckBox : public QCheckBox
|
|||||||
public:
|
public:
|
||||||
explicit TASCheckBox(const QString& text);
|
explicit TASCheckBox(const QString& text);
|
||||||
|
|
||||||
bool GetValue();
|
bool GetValue() const;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void mousePressEvent(QMouseEvent* event) override;
|
void mousePressEvent(QMouseEvent* event) override;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user