i18n corrected

libqt5sql5-sqlite appended to the dependency list
lgtm alerts fixed
added message forwarder to global settings
subscribe type leds-update appended (thanks @Brindosch)
Boblight server port check instead of error message
Race Condition of different priorities are prevented at startup

Signed-off-by: Paulchen-Panther <Paulchen-Panter@protonmail.com>
This commit is contained in:
Paulchen-Panther
2019-07-20 11:28:16 +02:00
parent 3a488e703c
commit af416ba5fc
18 changed files with 72 additions and 829 deletions

View File

@@ -7,9 +7,13 @@
// hyperion includes
#include <hyperion/Hyperion.h>
// qt incl
#include <QTcpServer>
// netUtil
#include <utils/NetUtils.h>
using namespace hyperion;
BoblightServer::BoblightServer(Hyperion* hyperion,const QJsonDocument& config)
@@ -42,11 +46,9 @@ void BoblightServer::start()
if ( _server->isListening() )
return;
if (!_server->listen(QHostAddress::Any, _port))
{
Error(_log, "Could not bind to port '%d', please use an available port", _port);
return;
}
if (NetUtils::portAvailable(_port, _log))
_server->listen(QHostAddress::Any, _port);
Info(_log, "Started on port %d", _port);
_hyperion->getComponentRegister().componentStateChanged(COMP_BOBLIGHTSERVER, _server->isListening());