diff options
author | Steru <jerrydream111@gmail.com> | 2024-08-15 23:27:54 +0200 |
---|---|---|
committer | Steru <jerrydream111@gmail.com> | 2024-08-16 23:53:31 +0200 |
commit | b869b8983656b12f9dee59439acfb6b3db647b72 (patch) | |
tree | 9bbb90ed4bfd6c9937beb3f5871ce2a6fbaa7059 /src/model/MedalWinner.cpp | |
parent | 4f12d941f949bb8b8c1d043ac34772c5c80f1b89 (diff) |
Made Competitor a QObject and tidied up some code.
Diffstat (limited to 'src/model/MedalWinner.cpp')
-rw-r--r-- | src/model/MedalWinner.cpp | 8 |
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. |