Feat: add letter property to timer

This commit is contained in:
Dorian Zedler 2023-05-14 22:35:10 +02:00
parent 206d55f301
commit 375fd906e2
Signed by: dorian
GPG Key ID: 989DE36109AFA354
2 changed files with 12 additions and 0 deletions

View File

@ -64,6 +64,7 @@ class ScStwRemoteRace;
class ScStwTimer : public QObject
{
Q_OBJECT
Q_PROPERTY(QString letter READ getLetter WRITE setLetter)
public:
explicit ScStwTimer(QObject *parent = nullptr);
@ -244,6 +245,13 @@ public slots:
*/
QString getLetter();
/*!
* \brief Function to set the letter of the timer
* \param letter the letter
* \return The letter of the timer or ""
*/
void setLetter(QString letter);
/*!
* \brief Function to set if the timer is supposed to be disabled
*

View File

@ -231,6 +231,10 @@ QString ScStwTimer::getLetter() {
return this->letter;
}
void ScStwTimer::setLetter(QString letter) {
this->letter = letter;
}
QString ScStwTimer::getText() {
QString newText = "";
int newTime = 0;