mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
Pass primitive types by value (#935)
This commit is contained in:
@@ -60,7 +60,7 @@
|
||||
|
||||
HyperionDaemon *HyperionDaemon::daemon = nullptr;
|
||||
|
||||
HyperionDaemon::HyperionDaemon(const QString rootPath, QObject *parent, const bool &logLvlOverwrite)
|
||||
HyperionDaemon::HyperionDaemon(const QString rootPath, QObject *parent, bool logLvlOverwrite)
|
||||
: QObject(parent), _log(Logger::getInstance("DAEMON"))
|
||||
, _instanceManager(new HyperionIManager(rootPath, this))
|
||||
, _authManager(new AuthManager(this))
|
||||
@@ -154,7 +154,7 @@ HyperionDaemon::~HyperionDaemon()
|
||||
delete _pyInit;
|
||||
}
|
||||
|
||||
void HyperionDaemon::setVideoMode(const VideoMode &mode)
|
||||
void HyperionDaemon::setVideoMode(VideoMode mode)
|
||||
{
|
||||
if (_currVideoMode != mode)
|
||||
{
|
||||
@@ -163,7 +163,7 @@ void HyperionDaemon::setVideoMode(const VideoMode &mode)
|
||||
}
|
||||
}
|
||||
|
||||
const QJsonDocument HyperionDaemon::getSetting(const settings::type &type)
|
||||
QJsonDocument HyperionDaemon::getSetting(settings::type type) const
|
||||
{
|
||||
return _settingsManager->getSetting(type);
|
||||
}
|
||||
@@ -312,7 +312,7 @@ void HyperionDaemon::startNetworkServices()
|
||||
ssdpThread->start();
|
||||
}
|
||||
|
||||
void HyperionDaemon::handleSettingsUpdate(const settings::type &settingsType, const QJsonDocument &config)
|
||||
void HyperionDaemon::handleSettingsUpdate(settings::type settingsType, const QJsonDocument &config)
|
||||
{
|
||||
if (settingsType == settings::LOGGER)
|
||||
{
|
||||
|
@@ -80,7 +80,7 @@ class HyperionDaemon : public QObject
|
||||
friend SysTray;
|
||||
|
||||
public:
|
||||
HyperionDaemon(QString rootPath, QObject *parent, const bool& logLvlOverwrite);
|
||||
HyperionDaemon(QString rootPath, QObject *parent, bool logLvlOverwrite);
|
||||
~HyperionDaemon();
|
||||
|
||||
///
|
||||
@@ -91,12 +91,12 @@ public:
|
||||
///
|
||||
/// @brief Get the current videoMode
|
||||
///
|
||||
const VideoMode & getVideoMode() { return _currVideoMode; };
|
||||
VideoMode getVideoMode() const { return _currVideoMode; };
|
||||
|
||||
///
|
||||
/// @brief get the settings
|
||||
///
|
||||
const QJsonDocument getSetting(const settings::type& type);
|
||||
QJsonDocument getSetting(settings::type type) const;
|
||||
|
||||
void startNetworkServices();
|
||||
|
||||
@@ -114,7 +114,7 @@ signals:
|
||||
///
|
||||
/// @brief After eval of setVideoMode this signal emits with a new one on change
|
||||
///
|
||||
void videoMode(const VideoMode& mode);
|
||||
void videoMode(VideoMode mode);
|
||||
|
||||
///////////////////////////////////////
|
||||
/// FROM HYPERION TO HYPERIONDAEMON ///
|
||||
@@ -123,12 +123,12 @@ signals:
|
||||
///
|
||||
/// @brief PIPE settings events from Hyperion class to HyperionDaemon components
|
||||
///
|
||||
void settingsChanged(const settings::type& type, const QJsonDocument& data);
|
||||
void settingsChanged(settings::type type, const QJsonDocument& data);
|
||||
|
||||
///
|
||||
/// @brief PIPE component state changes events from Hyperion class to HyperionDaemon components
|
||||
///
|
||||
void compStateChangeRequest(const hyperion::Components component, bool enable);
|
||||
void compStateChangeRequest(hyperion::Components component, bool enable);
|
||||
|
||||
private slots:
|
||||
///
|
||||
@@ -136,13 +136,13 @@ private slots:
|
||||
/// @param type settingyType from enum
|
||||
/// @param config configuration object
|
||||
///
|
||||
void handleSettingsUpdate(const settings::type& type, const QJsonDocument& config);
|
||||
void handleSettingsUpdate(settings::type type, const QJsonDocument& config);
|
||||
|
||||
///
|
||||
/// @brief Listen for videoMode changes and emit videoMode in case of a change, update _currVideoMode
|
||||
/// @param mode The requested video mode
|
||||
///
|
||||
void setVideoMode(const VideoMode& mode);
|
||||
void setVideoMode(VideoMode mode);
|
||||
|
||||
private:
|
||||
void createGrabberDispmanx();
|
||||
|
@@ -50,7 +50,7 @@ using namespace commandline;
|
||||
#define PERM0664 QFileDevice::ReadOwner | QFileDevice::ReadGroup | QFileDevice::ReadOther | QFileDevice::WriteOwner | QFileDevice::WriteGroup
|
||||
|
||||
#ifndef _WIN32
|
||||
void signal_handler(const int signum)
|
||||
void signal_handler(int signum)
|
||||
{
|
||||
// Hyperion Managment instance
|
||||
HyperionIManager *_hyperion = HyperionIManager::getInstance();
|
||||
|
@@ -211,7 +211,7 @@ void SysTray::clearEfxColor()
|
||||
_hyperion->clear(1);
|
||||
}
|
||||
|
||||
void SysTray::handleInstanceStateChange(const InstanceState& state, const quint8& instance, const QString& name)
|
||||
void SysTray::handleInstanceStateChange(InstanceState state, quint8 instance, const QString& name)
|
||||
{
|
||||
switch(state){
|
||||
case InstanceState::H_STARTED:
|
||||
|
@@ -35,12 +35,12 @@ private slots:
|
||||
///
|
||||
/// @brief is called whenever the webserver changes the port
|
||||
///
|
||||
void webserverPortChanged(const quint16& port) { _webPort = port; };
|
||||
void webserverPortChanged(quint16 port) { _webPort = port; };
|
||||
|
||||
///
|
||||
/// @brief is called whenever a hyperion instance state changes
|
||||
///
|
||||
void handleInstanceStateChange(const InstanceState& state, const quint8& instance, const QString& name);
|
||||
void handleInstanceStateChange(InstanceState state, quint8 instance, const QString& name);
|
||||
|
||||
private:
|
||||
void createTrayIcon();
|
||||
|
Reference in New Issue
Block a user