Fix typos

master
Simon Stürz 2022-02-18 06:22:28 +01:00
parent bcd243d83e
commit 39d55877d9
3 changed files with 27 additions and 28 deletions

View File

@ -211,7 +211,6 @@ void IntegrationPluginKeba::setupThing(ThingSetupInfo *info)
}
}
m_kebaDevices.insert(thing->id(), keba);
info->finish(Thing::ThingErrorNoError);
qCDebug(dcKeba()) << "Setup finsihed successfully for" << thing << thing->params();

View File

@ -52,8 +52,8 @@ KebaProductInfo::KebaProductInfo(const QString &productString) :
m_connector = ConnectorSocket;
qCDebug(dcKeba()) << "Connector: Socket";
} else if (connectorValue.toLower() == QChar('c')) {
m_connector = ConnectorCabel;
qCDebug(dcKeba()) << "Connector: Cabel";
m_connector = ConnectorCable;
qCDebug(dcKeba()) << "Connector: Cable";
} else {
m_isValid = false;
return;
@ -89,19 +89,19 @@ KebaProductInfo::KebaProductInfo(const QString &productString) :
qCDebug(dcKeba()) << "Current:" << m_current;
QString cabelValue = m_productString.mid(11, 2);
if (cabelValue == "00") {
m_cabel = NoCabel;
qCDebug(dcKeba()) << "Cabel: No cabel";
} else if (cabelValue == "01") {
m_cabel = Cabel4m;
qCDebug(dcKeba()) << "Cabel: 4 meter";
} else if (cabelValue == "04") {
m_cabel = Cabel6m;
qCDebug(dcKeba()) << "Cabel: 6 meter";
} else if (cabelValue == "07") {
m_cabel = Cabel5p5m;
qCDebug(dcKeba()) << "Cabel: 5.5 meter";
QString cableValue = m_productString.mid(11, 2);
if (cableValue == "00") {
m_cable = NoCable;
qCDebug(dcKeba()) << "Cable: No cable";
} else if (cableValue == "01") {
m_cable = Cable4m;
qCDebug(dcKeba()) << "Cable: 4 meter";
} else if (cableValue == "04") {
m_cable = Cable6m;
qCDebug(dcKeba()) << "Cable: 6 meter";
} else if (cableValue == "07") {
m_cable = Cable5p5m;
qCDebug(dcKeba()) << "Cable: 5.5 meter";
} else {
m_isValid = false;
return;
@ -223,9 +223,9 @@ KebaProductInfo::ConnectorCurrent KebaProductInfo::current() const
return m_current;
}
KebaProductInfo::Cabel KebaProductInfo::cabel() const
KebaProductInfo::Cable KebaProductInfo::cable() const
{
return m_cabel;
return m_cable;
}
KebaProductInfo::Series KebaProductInfo::series() const

View File

@ -40,7 +40,7 @@ class KebaProductInfo
public:
enum Connector {
ConnectorSocket,
ConnectorCabel
ConnectorCable
};
Q_ENUM(Connector)
@ -59,13 +59,13 @@ public:
};
Q_ENUM(ConnectorCurrent)
enum Cabel {
NoCabel = 0,
Cabel4m = 1,
Cabel6m = 4,
Cabel5p5m = 7
enum Cable {
NoCable = 0,
Cable4m = 1,
Cable6m = 4,
Cable5p5m = 7
};
Q_ENUM(Cabel)
Q_ENUM(Cable)
enum Series {
SeriesE,
@ -104,10 +104,10 @@ public:
// Porperties in the string
QString model() const; // KC-P30
QString countryCode() const; // E
Connector connector() const; // Socket / Cabel
Connector connector() const; // Socket / Cable
ConnectorType connectorType() const; // Type 1 / Type 2
ConnectorCurrent current() const; // 13A, 16A ...
Cabel cabel() const; // 4m, 6m...
Cable cable() const; // 4m, 6m...
Series series() const; // x, c, a...
int phaseCount() const; // 1 or 3
Meter meter() const; // No meter, Calibrated, ...
@ -122,7 +122,7 @@ private:
Connector m_connector;
ConnectorType m_connectorType;
ConnectorCurrent m_current;
Cabel m_cabel;
Cable m_cable;
Series m_series;
int m_phaseCount;
Meter m_meter;