General tidy up

This commit is contained in:
Murat
2020-08-08 00:21:19 +02:00
parent 13205a9d11
commit dd2d5e4b40
62 changed files with 117 additions and 296 deletions

View File

@@ -117,10 +117,7 @@ YeelightLight::YeelightLight( Logger *log, const QString &hostname, quint16 port
YeelightLight::~YeelightLight()
{
log (3,"~YeelightLight()","" );
if ( _tcpSocket != nullptr)
{
delete _tcpSocket;
}
delete _tcpSocket;
log (2,"~YeelightLight()","void" );
}
@@ -968,7 +965,7 @@ void YeelightLight::log(const int logLevel, const char* msg, const char* type, .
//---------------------------------------------------------------------------------
LedDeviceYeelight::LedDeviceYeelight(const QJsonObject &deviceConfig)
: LedDevice()
: LedDevice(deviceConfig)
,_lightsCount (0)
,_outputColorModel(0)
,_transitionEffect(YeelightLight::API_EFFECT_SMOOTH)
@@ -982,10 +979,6 @@ LedDeviceYeelight::LedDeviceYeelight(const QJsonObject &deviceConfig)
,_debuglevel(0)
,_musicModeServerPort(-1)
{
_devConfig = deviceConfig;
_isDeviceReady = false;
_activeDeviceType = deviceConfig["type"].toString("UNSPECIFIED").toLower();
}
LedDeviceYeelight::~LedDeviceYeelight()