13#include <QQmlParserStatus>
16#include <qqmlregistration.h>
18#include "formatter/Unit.h"
20#include "sensors_export.h"
43 Q_PROPERTY(
QString sensorId READ sensorId WRITE setSensorId NOTIFY sensorIdChanged)
47 Q_PROPERTY(
QString name READ name NOTIFY metaDataChanged)
53 Q_PROPERTY(
QString shortName READ shortName NOTIFY metaDataChanged)
57 Q_PROPERTY(
QString description READ description NOTIFY metaDataChanged)
61 Q_PROPERTY(KSysGuard::Unit unit READ unit NOTIFY metaDataChanged)
65 Q_PROPERTY(qreal minimum READ minimum NOTIFY metaDataChanged)
69 Q_PROPERTY(qreal maximum READ maximum NOTIFY metaDataChanged)
75 Q_PROPERTY(
QVariant::Type type READ type NOTIFY metaDataChanged)
88 Q_PROPERTY(
QVariant value READ value NOTIFY valueChanged)
92 Q_PROPERTY(
QString formattedValue READ formattedValue NOTIFY valueChanged)
99 Q_PROPERTY(
bool enabled READ enabled WRITE setEnabled NOTIFY enabledChanged)
110 Q_PROPERTY(uint updateInterval READ updateInterval NOTIFY updateIntervalChanged)
119 Q_PROPERTY(
int updateRateLimit READ updateRateLimit WRITE setUpdateRateLimit NOTIFY updateRateLimitChanged RESET resetUpdateRateLimit)
144 bool event(
QEvent *event)
override;
147 void setSensorId(
const QString &
id);
148 Q_SIGNAL
void sensorIdChanged()
const;
151 Q_SIGNAL
void statusChanged()
const;
156 KSysGuard::Unit unit()
const;
157 qreal minimum()
const;
158 qreal maximum()
const;
178 QString formattedValue()
const;
179 Q_SIGNAL
void valueChanged()
const;
181 bool enabled()
const;
182 void setEnabled(
bool newEnabled);
183 Q_SIGNAL
void enabledChanged();
185 uint updateInterval()
const;
186 Q_SIGNAL
void updateIntervalChanged();
188 int updateRateLimit()
const;
189 void setUpdateRateLimit(
int newUpdateRateLimit);
190 void resetUpdateRateLimit();
191 Q_SIGNAL
void updateRateLimitChanged();
193 void classBegin()
override;
194 void componentComplete()
override;
197 void onMetaDataChanged(
const QString &sensorId,
const SensorInfo &metaData);
199 void onEnabledChanged();
202 const std::unique_ptr<Private> d;
An object to query the daemon for a list of sensors and their metadata.
An object encapsulating a backend sensor.
Status
This enum type is used to specify status of the Sensor.
Q_SIGNAL void metaDataChanged() const
This signal is emitted when any of the metadata properties change.
Q_SCRIPTABLE CaptureState status()
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:19:45 by
doxygen 1.12.0 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.