Initial commit
This commit is contained in:
commit
b7d90b9afe
16245 files changed
+3396666
No files matched your search
+59
@@ -0,0 +1,59 @@
|
||||
/**
|
||||
*@RDE_HEADER@
|
||||
* Ui for displaying Relay Infos
|
||||
* $Id$
|
||||
* $HeadURL$
|
||||
* $Author$
|
||||
* Created by Malte Diers, SLTE, 2021-04-27
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <QWidget>
|
||||
#include <Buildings/bld_enums.hpp>
|
||||
#include <InfrastructureManagement/ism_enums.hpp>
|
||||
#include <QDateTime>
|
||||
#include <Buildings/logger.h>
|
||||
|
||||
namespace Ui {
|
||||
class RelayInfoWidget;
|
||||
}
|
||||
|
||||
|
||||
namespace Buildings
|
||||
{
|
||||
|
||||
class RelayInfoWidget : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit RelayInfoWidget(int id, QWidget *parent = nullptr);
|
||||
~RelayInfoWidget();
|
||||
|
||||
QString name() const;
|
||||
bool state() const;
|
||||
int id() const;
|
||||
|
||||
signals:
|
||||
void effectOverrideChanged(int relayId, InfrastructureManagement::EffectOverride override);
|
||||
|
||||
public slots:
|
||||
void setName(const QString &name);
|
||||
void setState(bool state, qint64 stateTime, qint64 offlineTime);
|
||||
void setEffectOverride(InfrastructureManagement::EffectOverride override);
|
||||
void setEffectOverrideEnabled(InfrastructureManagement::EffectOverride override, bool enable = true);
|
||||
void setLedVisible(bool enable = true);
|
||||
void setOfflineColor();
|
||||
|
||||
private slots:
|
||||
void onButtonClicked();
|
||||
|
||||
private:
|
||||
int m_id;
|
||||
bool m_state;
|
||||
Ui::RelayInfoWidget *m_ui;
|
||||
LOGGER_T m_logger;
|
||||
};
|
||||
|
||||
} // namespace
|
||||
Reference in new issue
Block a user