summaryrefslogtreecommitdiff
path: root/src/model/MedalWinner.cpp
diff options
context:
space:
mode:
authorSteru <jerrydream111@gmail.com>2024-08-15 23:27:54 +0200
committerOrangerot <purple@orangerot.dev>2024-08-26 11:19:38 +0200
commitb6c86f02ff7ecb74cc96af61d8216b232bcecb3e (patch)
tree26def991cecebcaf8704a5194ae84d4bfe137951 /src/model/MedalWinner.cpp
parentdb2d0c21c48698d336ac6e60c42cc2533648b51d (diff)
Made Competitor a QObject and tidied up some code.
Diffstat (limited to 'src/model/MedalWinner.cpp')
-rw-r--r--src/model/MedalWinner.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/model/MedalWinner.cpp b/src/model/MedalWinner.cpp
index 4eca811..bdf6ee3 100644
--- a/src/model/MedalWinner.cpp
+++ b/src/model/MedalWinner.cpp
@@ -14,16 +14,16 @@ bool MedalWinner::setMedals(const QJsonObject &medals) {
throw invalid_argument("Medal object of competitor is incomplete.");
}
- this->gold = medals["ME_GOLD"].toInt();
- this->silver = medals["ME_SILVER"].toInt();
- this->bronze = medals["ME_BRONZE"].toInt();
+ this->m_gold = medals["ME_GOLD"].toInt();
+ this->m_silver = medals["ME_SILVER"].toInt();
+ this->m_bronze = medals["ME_BRONZE"].toInt();
return true;
}
/**
* Static compare method, which can compare the amount of medals of two MedalWinners.
- * Gold has the highest priority, then silver and finally bronze.
+ * Gold has the highest priority, then m_silver and finally m_bronze.
*
* @param lComp First competitor to compare.
* @param rComp Second competitor to compare.