Merge remote-tracking branch 'origin/master'

This commit is contained in:
Dorian Zedler 2020-10-03 18:33:43 +02:00
commit 2d3c60b649
Signed by: dorian
GPG key ID: D3B255CB8BC7CD37
4 changed files with 9 additions and 8 deletions

View file

@ -60,12 +60,13 @@ public slots:
private slots: private slots:
void handleBaseStationSignal(ScStw::SignalKey key, QVariant data); void handleBaseStationSignal(ScStw::SignalKey key, QVariant data);
void handleSettingChange(int keyInt, int keyLevel, QVariant value);
bool refreshRemoteTimers(QVariantList remoteTimers); bool refreshRemoteTimers(QVariantList remoteTimers);
void rebuildRemoteTimers(QVariantList remoteTimers); void rebuildRemoteTimers(QVariantList remoteTimers);
void refreshDetails(QVariantMap details); void refreshDetails(QVariantMap details);
void handleClientStateChange(); void handleClientStateChange();
void refreshCompetitionMode();
RaceMode getMode(); RaceMode getMode();
bool local(); bool local();
}; };

View file

@ -129,12 +129,6 @@ bool ScStwRemoteRace::local() {
return this->getMode() == LOCAL; return this->getMode() == LOCAL;
} }
void ScStwRemoteRace::handleSettingChange(int keyInt, int keyLevel, QVariant value) {
if(this->local())
return ScStwRace::handleSettingChange(keyInt, keyLevel, value);
}
/** /**
* @brief ScStwAppBackend::handleBaseStationUpdate * @brief ScStwAppBackend::handleBaseStationUpdate
* *
@ -292,3 +286,8 @@ bool ScStwRemoteRace::getReadySoundEnabled() {
return this->readySoundEnabled; return this->readySoundEnabled;
} }
void ScStwRemoteRace::refreshCompetitionMode() {
if(this->local())
return ScStwRace::refreshCompetitionMode();
}

View file

@ -30,7 +30,7 @@ void ScStwLibraries::init() {
qRegisterMetaType<ScStw::SocketCommand>("ScStw::SocketCommand"); qRegisterMetaType<ScStw::SocketCommand>("ScStw::SocketCommand");
qRegisterMetaType<ScStw::StatusCode>("ScStw::StatusCode"); qRegisterMetaType<ScStw::StatusCode>("ScStw::StatusCode");
qmlRegisterType<ScStwRace>("de.itsblue.ScStw", 2, 0, "ScStwRace"); qmlRegisterUncreatableType<ScStwRace>("de.itsblue.ScStw", 2, 0, "ScStwRace", "ScStwRace is not creatable");
qmlRegisterType<ScStwTimer>("de.itsblue.ScStw", 2, 0, "ScStwTimer"); qmlRegisterType<ScStwTimer>("de.itsblue.ScStw", 2, 0, "ScStwTimer");
#ifdef ScStwLibraries_ClientLibs #ifdef ScStwLibraries_ClientLibs

View file

@ -692,6 +692,7 @@ QVariantList ScStwRace::getTimerDetailList() {
tmpTimer.insert("reactionTime", timer->getReactionTime()); tmpTimer.insert("reactionTime", timer->getReactionTime());
tmpTimer.insert("letter", timer->getLetter()); tmpTimer.insert("letter", timer->getLetter());
tmpTimer.insert("readyState", timer->getReadyState()); tmpTimer.insert("readyState", timer->getReadyState());
tmpTimer.insert("text", timer->getText());
tmpTimers.append(tmpTimer); tmpTimers.append(tmpTimer);
} }