Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Use more explicit

parent a4636545
......@@ -38,7 +38,7 @@ class CardPort : public Port
Q_OBJECT
Q_PROPERTY(QVariantMap properties READ properties NOTIFY propertiesChanged)
public:
CardPort(QObject *parent = nullptr) : Port(parent) {}
explicit CardPort(QObject *parent = nullptr) : Port(parent) {}
~CardPort() override {}
// int direction; /**< A #pa_direction enum, indicating the direction of this port. */
......@@ -83,7 +83,7 @@ class Card : public PulseObject
Q_PROPERTY(quint32 activeProfileIndex READ activeProfileIndex WRITE setActiveProfileIndex NOTIFY activeProfileIndexChanged)
Q_PROPERTY(QList<QObject *> ports READ ports NOTIFY portsChanged)
public:
Card(QObject *parent);
explicit Card(QObject *parent);
void update(const pa_card_info *info);
......
......@@ -35,7 +35,7 @@ class Client : public PulseObject
Q_OBJECT
Q_PROPERTY(QString name READ name NOTIFY nameChanged)
public:
Client(QObject *parent);
explicit Client(QObject *parent);
~Client() override;
void update(const pa_client_info *info);
......
......@@ -42,7 +42,7 @@ class Context : public QObject
{
Q_OBJECT
public:
Context(QObject *parent = nullptr);
explicit Context(QObject *parent = nullptr);
~Context() override;
static Context *instance();
......
......@@ -126,7 +126,7 @@ signals:
void defaultChanged();
protected:
Device(QObject *parent);
explicit Device(QObject *parent);
private:
State stateFromPaState(int value) const;
......
......@@ -38,7 +38,7 @@ class Module : public PulseObject
Q_PROPERTY(QString argument READ argument NOTIFY argumentChanged)
public:
Module(QObject *parent);
explicit Module(QObject *parent);
void update(const pa_module_info *info);
......
......@@ -42,7 +42,7 @@ class ModuleManager : public QObject
Q_PROPERTY(bool switchOnConnect READ switchOnConnect WRITE setSwitchOnConnect NOTIFY switchOnConnectChanged)
Q_PROPERTY(QStringList loadedModules READ loadedModules NOTIFY loadedModulesChanged)
public:
ModuleManager(QObject *parent = nullptr);
explicit ModuleManager(QObject *parent = nullptr);
~ModuleManager() override;
bool combineSinks() const;
void setCombineSinks(bool combineSinks);
......
......@@ -40,7 +40,7 @@ public:
* @brief PAOperation
* @param operation operation to manage the scope of
*/
PAOperation(pa_operation *operation = nullptr);
explicit PAOperation(pa_operation *operation = nullptr);
~PAOperation();
PAOperation &operator =(pa_operation *operation);
......
......@@ -34,7 +34,7 @@ class Port : public Profile
public:
Port(QObject *parent);
explicit Port(QObject *parent);
~Port() override;
template<typename PAInfo>
......
......@@ -43,7 +43,7 @@ public:
};
Q_ENUM(Availability)
Profile(QObject *parent);
explicit Profile(QObject *parent);
~Profile() override;
template<typename PAInfo>
......
......@@ -74,7 +74,7 @@ class CardModel : public AbstractModel
{
Q_OBJECT
public:
CardModel(QObject *parent = nullptr);
explicit CardModel(QObject *parent = nullptr);
};
class SinkModel : public AbstractModel
......@@ -88,7 +88,7 @@ public:
};
Q_ENUMS(ItemRole)
SinkModel(QObject *parent = nullptr);
explicit SinkModel(QObject *parent = nullptr);
Sink *defaultSink() const;
Sink *preferredSink() const;
QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override;
......@@ -110,7 +110,7 @@ class SinkInputModel : public AbstractModel
{
Q_OBJECT
public:
SinkInputModel(QObject *parent = nullptr);
explicit SinkInputModel(QObject *parent = nullptr);
};
class SourceModel : public AbstractModel
......@@ -123,7 +123,7 @@ public:
};
Q_ENUMS(ItemRole)
SourceModel(QObject *parent = nullptr);
explicit SourceModel(QObject *parent = nullptr);
Source *defaultSource() const;
QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override;
......@@ -135,21 +135,21 @@ class SourceOutputModel : public AbstractModel
{
Q_OBJECT
public:
SourceOutputModel(QObject *parent = nullptr);
explicit SourceOutputModel(QObject *parent = nullptr);
};
class StreamRestoreModel : public AbstractModel
{
Q_OBJECT
public:
StreamRestoreModel(QObject *parent = nullptr);
explicit StreamRestoreModel(QObject *parent = nullptr);
};
class ModuleModel : public AbstractModel
{
Q_OBJECT
public:
ModuleModel(QObject *parent = nullptr);
explicit ModuleModel(QObject *parent = nullptr);
};
} // QPulseAudio
......
......@@ -66,7 +66,7 @@ signals:
void propertiesChanged();
protected:
PulseObject(QObject *parent);
explicit PulseObject(QObject *parent);
~PulseObject() override;
Context *context() const;
......
......@@ -28,7 +28,7 @@ class GlobalAction : public QAction
{
Q_OBJECT
public:
GlobalAction(QObject *parent = nullptr);
explicit GlobalAction(QObject *parent = nullptr);
};
class GlobalActionCollection : public QQuickItem
......
......@@ -27,7 +27,7 @@ class VolumeOSD : public QObject
{
Q_OBJECT
public:
VolumeOSD(QObject *parent = nullptr);
explicit VolumeOSD(QObject *parent = nullptr);
public slots:
void show(int percent);
......
......@@ -30,7 +30,7 @@ class Sink : public Device
{
Q_OBJECT
public:
Sink(QObject *parent);
explicit Sink(QObject *parent);
void update(const pa_sink_info *info);
void setVolume(qint64 volume) override;
......
......@@ -30,7 +30,7 @@ class SinkInput : public Stream
{
Q_OBJECT
public:
SinkInput(QObject *parent);
explicit SinkInput(QObject *parent);
void update(const pa_sink_input_info *info);
......
......@@ -30,7 +30,7 @@ class Source : public Device
{
Q_OBJECT
public:
Source(QObject *parent);
explicit Source(QObject *parent);
void update(const pa_source_info *info);
void setVolume(qint64 volume) override;
......
......@@ -30,7 +30,7 @@ class SourceOutput : public Stream
{
Q_OBJECT
public:
SourceOutput(QObject *parent);
explicit SourceOutput(QObject *parent);
void update(const pa_source_output_info *info);
......
......@@ -91,7 +91,7 @@ signals:
void corkedChanged();
protected:
Stream(QObject *parent);
explicit Stream(QObject *parent);
~Stream() override;
quint32 m_deviceIndex;
......
......@@ -38,7 +38,7 @@ class VolumeObject : public PulseObject
Q_PROPERTY(QStringList channels READ channels NOTIFY channelsChanged)
Q_PROPERTY(QList<qreal> channelVolumes READ channelVolumes NOTIFY channelVolumesChanged)
public:
VolumeObject(QObject *parent);
explicit VolumeObject(QObject *parent);
~VolumeObject() override;
template <typename PAInfo>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment