Drop old unused cloudEnabled settings
This commit is contained in:
parent
8b3f933f0c
commit
d648a178f8
@ -106,18 +106,6 @@ void NymeaConfiguration::setDebugServerEnabled(bool debugServerEnabled)
|
|||||||
m_client->sendCommand("Configuration.SetDebugServerEnabled", params, this, "setDebugServerEnabledResponse");
|
m_client->sendCommand("Configuration.SetDebugServerEnabled", params, this, "setDebugServerEnabledResponse");
|
||||||
}
|
}
|
||||||
|
|
||||||
bool NymeaConfiguration::cloudEnabled() const
|
|
||||||
{
|
|
||||||
return m_cloudEnabled;
|
|
||||||
}
|
|
||||||
|
|
||||||
void NymeaConfiguration::setCloudEnabled(bool cloudEnabled)
|
|
||||||
{
|
|
||||||
QVariantMap params;
|
|
||||||
params.insert("enabled", cloudEnabled);
|
|
||||||
m_client->sendCommand("Configuration.SetCloudEnabled", params, this, "setCloudEnabledResponse");
|
|
||||||
}
|
|
||||||
|
|
||||||
ServerConfigurations *NymeaConfiguration::tcpServerConfigurations() const
|
ServerConfigurations *NymeaConfiguration::tcpServerConfigurations() const
|
||||||
{
|
{
|
||||||
return m_tcpServerConfigurations;
|
return m_tcpServerConfigurations;
|
||||||
@ -302,8 +290,6 @@ void NymeaConfiguration::getConfigurationsResponse(int commandId, const QVariant
|
|||||||
m_serverName = basicConfig.value("serverName").toString();
|
m_serverName = basicConfig.value("serverName").toString();
|
||||||
emit serverNameChanged();
|
emit serverNameChanged();
|
||||||
QVariantMap cloudConfig = params.value("cloud").toMap();
|
QVariantMap cloudConfig = params.value("cloud").toMap();
|
||||||
m_cloudEnabled = cloudConfig.value("enabled").toBool();
|
|
||||||
emit cloudEnabledChanged();
|
|
||||||
|
|
||||||
tcpServerConfigurations()->clear();
|
tcpServerConfigurations()->clear();
|
||||||
foreach (const QVariant &tcpServerVariant, params.value("tcpServerConfigurations").toList()) {
|
foreach (const QVariant &tcpServerVariant, params.value("tcpServerConfigurations").toList()) {
|
||||||
@ -356,11 +342,6 @@ void NymeaConfiguration::getCloudConfigurationResponse(const QVariantMap ¶ms
|
|||||||
qCDebug(dcNymeaConfiguration) << "Cloud config reply" << params;
|
qCDebug(dcNymeaConfiguration) << "Cloud config reply" << params;
|
||||||
}
|
}
|
||||||
|
|
||||||
void NymeaConfiguration::setCloudEnabledResponse(int commandId, const QVariantMap ¶ms)
|
|
||||||
{
|
|
||||||
qCDebug(dcNymeaConfiguration) << "Set cloud enabled:" << commandId << params;
|
|
||||||
}
|
|
||||||
|
|
||||||
void NymeaConfiguration::setDebugServerEnabledResponse(int commandId, const QVariantMap ¶ms)
|
void NymeaConfiguration::setDebugServerEnabledResponse(int commandId, const QVariantMap ¶ms)
|
||||||
{
|
{
|
||||||
qCDebug(dcNymeaConfiguration) << "Debug server set:" << commandId << params;
|
qCDebug(dcNymeaConfiguration) << "Debug server set:" << commandId << params;
|
||||||
@ -467,11 +448,6 @@ void NymeaConfiguration::notificationReceived(const QVariantMap ¬ification)
|
|||||||
m_serverName = configMap.value("serverName").toString();
|
m_serverName = configMap.value("serverName").toString();
|
||||||
emit serverNameChanged();
|
emit serverNameChanged();
|
||||||
qCDebug(dcNymeaConfiguration()) << "Basic configuration changed. Server name:" << m_serverName << "Debug server enabled:" << m_debugServerEnabled;
|
qCDebug(dcNymeaConfiguration()) << "Basic configuration changed. Server name:" << m_serverName << "Debug server enabled:" << m_debugServerEnabled;
|
||||||
} else if (notif == "Configuration.CloudConfigurationChanged") {
|
|
||||||
QVariantMap configMap = params.value("cloudConfiguration").toMap();
|
|
||||||
qCDebug(dcNymeaConfiguration()) << "Cloud coniguration changed" << configMap;
|
|
||||||
m_cloudEnabled = configMap.value("enabled").toBool();
|
|
||||||
emit cloudEnabledChanged();
|
|
||||||
} else if (notif == "Configuration.TcpServerConfigurationChanged") {
|
} else if (notif == "Configuration.TcpServerConfigurationChanged") {
|
||||||
QVariantMap configMap = params.value("tcpServerConfiguration").toMap();
|
QVariantMap configMap = params.value("tcpServerConfiguration").toMap();
|
||||||
QString id = configMap.value("id").toString();
|
QString id = configMap.value("id").toString();
|
||||||
|
|||||||
@ -51,7 +51,6 @@ class NymeaConfiguration : public QObject
|
|||||||
|
|
||||||
Q_PROPERTY(QString serverName READ serverName WRITE setServerName NOTIFY serverNameChanged)
|
Q_PROPERTY(QString serverName READ serverName WRITE setServerName NOTIFY serverNameChanged)
|
||||||
|
|
||||||
Q_PROPERTY(bool cloudEnabled READ cloudEnabled WRITE setCloudEnabled NOTIFY cloudEnabledChanged)
|
|
||||||
Q_PROPERTY(bool debugServerEnabled READ debugServerEnabled WRITE setDebugServerEnabled NOTIFY debugServerEnabledChanged)
|
Q_PROPERTY(bool debugServerEnabled READ debugServerEnabled WRITE setDebugServerEnabled NOTIFY debugServerEnabledChanged)
|
||||||
|
|
||||||
Q_PROPERTY(ServerConfigurations* tcpServerConfigurations READ tcpServerConfigurations CONSTANT)
|
Q_PROPERTY(ServerConfigurations* tcpServerConfigurations READ tcpServerConfigurations CONSTANT)
|
||||||
@ -81,9 +80,6 @@ public:
|
|||||||
bool debugServerEnabled() const;
|
bool debugServerEnabled() const;
|
||||||
void setDebugServerEnabled(bool debugServerEnabled);
|
void setDebugServerEnabled(bool debugServerEnabled);
|
||||||
|
|
||||||
bool cloudEnabled() const;
|
|
||||||
void setCloudEnabled(bool cloudEnabled);
|
|
||||||
|
|
||||||
ServerConfigurations *tcpServerConfigurations() const;
|
ServerConfigurations *tcpServerConfigurations() const;
|
||||||
ServerConfigurations *webSocketServerConfigurations() const;
|
ServerConfigurations *webSocketServerConfigurations() const;
|
||||||
WebServerConfigurations *webServerConfigurations() const;
|
WebServerConfigurations *webServerConfigurations() const;
|
||||||
@ -118,7 +114,6 @@ private:
|
|||||||
Q_INVOKABLE void setDebugServerEnabledResponse(int commandId, const QVariantMap ¶ms);
|
Q_INVOKABLE void setDebugServerEnabledResponse(int commandId, const QVariantMap ¶ms);
|
||||||
Q_INVOKABLE void setServerNameResponse(int commandId, const QVariantMap ¶ms);
|
Q_INVOKABLE void setServerNameResponse(int commandId, const QVariantMap ¶ms);
|
||||||
Q_INVOKABLE void setTimezoneResponse(int commandId, const QVariantMap ¶ms);
|
Q_INVOKABLE void setTimezoneResponse(int commandId, const QVariantMap ¶ms);
|
||||||
Q_INVOKABLE void setCloudEnabledResponse(int commandId, const QVariantMap ¶ms);
|
|
||||||
Q_INVOKABLE void setTcpConfigReply(int commandId, const QVariantMap ¶ms);
|
Q_INVOKABLE void setTcpConfigReply(int commandId, const QVariantMap ¶ms);
|
||||||
Q_INVOKABLE void deleteTcpConfigReply(int commandId, const QVariantMap ¶ms);
|
Q_INVOKABLE void deleteTcpConfigReply(int commandId, const QVariantMap ¶ms);
|
||||||
Q_INVOKABLE void setWebSocketConfigReply(int commandId, const QVariantMap ¶ms);
|
Q_INVOKABLE void setWebSocketConfigReply(int commandId, const QVariantMap ¶ms);
|
||||||
@ -140,7 +135,6 @@ signals:
|
|||||||
void fetchingDataChanged();
|
void fetchingDataChanged();
|
||||||
void debugServerEnabledChanged();
|
void debugServerEnabledChanged();
|
||||||
void serverNameChanged();
|
void serverNameChanged();
|
||||||
void cloudEnabledChanged();
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
JsonRpcClient* m_client = nullptr;
|
JsonRpcClient* m_client = nullptr;
|
||||||
@ -148,7 +142,6 @@ private:
|
|||||||
bool m_fetchingData = false;
|
bool m_fetchingData = false;
|
||||||
bool m_debugServerEnabled = false;
|
bool m_debugServerEnabled = false;
|
||||||
QString m_serverName;
|
QString m_serverName;
|
||||||
bool m_cloudEnabled = false;
|
|
||||||
|
|
||||||
ServerConfigurations *m_tcpServerConfigurations = nullptr;
|
ServerConfigurations *m_tcpServerConfigurations = nullptr;
|
||||||
ServerConfigurations *m_webSocketServerConfigurations = nullptr;
|
ServerConfigurations *m_webSocketServerConfigurations = nullptr;
|
||||||
|
|||||||
Reference in New Issue
Block a user