summaryrefslogtreecommitdiffstats
path: root/app/audiorole.hpp
blob: afc36657f07ff5ba64cfe5868b620b04b71e6379 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#ifndef AUDIOROLE_H
#define AUDIOROLE_H

#include <QObject>

class AudioRole
	: public QObject
{
	Q_OBJECT
	Q_PROPERTY(QString name READ Name WRITE setName NOTIFY NameChanged)
	Q_PROPERTY(int value READ Value WRITE setValue NOTIFY ValueChanged)

private:
	QString m_Name;
	int m_Value;
	int m_Updating;

public:
	explicit AudioRole(QObject* parent = nullptr);
	explicit AudioRole(const QString& name, int value, QObject* parent = nullptr);

	QString Name() const;
	void setName(const QString& name);

	int Value() const;
	void setValue(int value);

	void BeginUpdate();
	void EndUpdate();

signals:
	void NameChanged();
	void ValueChanged();

public slots:
};

#endif // AUDIOROLE_H