diff --git a/src/matriximageprovider.h b/src/matriximageprovider.h index 6833d41f1..a3736e1c8 100644 --- a/src/matriximageprovider.h +++ b/src/matriximageprovider.h @@ -26,7 +26,7 @@ class ThumbnailResponse : public QQuickImageResponse { Q_OBJECT public: - ThumbnailResponse(QString mediaId, QSize requestedSize); + explicit ThumbnailResponse(QString mediaId, QSize requestedSize); ~ThumbnailResponse() override = default; private Q_SLOTS: diff --git a/src/models/completionmodel.h b/src/models/completionmodel.h index 6e80ffc82..6e41a34e9 100644 --- a/src/models/completionmodel.h +++ b/src/models/completionmodel.h @@ -71,7 +71,7 @@ public: }; Q_ENUM(Roles) - CompletionModel(QObject *parent = nullptr); + explicit CompletionModel(QObject *parent = nullptr); /** * @brief Get the given role value at the given index. diff --git a/src/models/mediamessagefiltermodel.h b/src/models/mediamessagefiltermodel.h index 44938996f..9158aee97 100644 --- a/src/models/mediamessagefiltermodel.h +++ b/src/models/mediamessagefiltermodel.h @@ -31,7 +31,7 @@ public: }; Q_ENUM(Roles) - MediaMessageFilterModel(QObject *parent = nullptr); + explicit MediaMessageFilterModel(QObject *parent = nullptr); /** * @brief Custom filter to show only image and video messages. diff --git a/src/models/messagefiltermodel.h b/src/models/messagefiltermodel.h index ae85371ca..890d24eb4 100644 --- a/src/models/messagefiltermodel.h +++ b/src/models/messagefiltermodel.h @@ -16,7 +16,7 @@ class MessageFilterModel : public QSortFilterProxyModel { Q_OBJECT public: - MessageFilterModel(QObject *parent = nullptr); + explicit MessageFilterModel(QObject *parent = nullptr); /** * @brief Custom filter function to remove hidden messages. diff --git a/src/models/publicroomlistmodel.h b/src/models/publicroomlistmodel.h index eff97c61d..989f7be3c 100644 --- a/src/models/publicroomlistmodel.h +++ b/src/models/publicroomlistmodel.h @@ -64,7 +64,7 @@ public: IsJoinedRole, /**< Whether the local user has joined the room. */ }; - PublicRoomListModel(QObject *parent = nullptr); + explicit PublicRoomListModel(QObject *parent = nullptr); /** * @brief Get the given role value at the given index. diff --git a/src/models/pushrulemodel.h b/src/models/pushrulemodel.h index 1e303baf2..19033fe2d 100644 --- a/src/models/pushrulemodel.h +++ b/src/models/pushrulemodel.h @@ -172,7 +172,7 @@ public: }; Q_ENUM(EventRoles) - PushRuleModel(QObject *parent = nullptr); + explicit PushRuleModel(QObject *parent = nullptr); [[nodiscard]] PushNotificationAction::Action defaultState() const; void setDefaultState(PushNotificationAction::Action defaultState); diff --git a/src/models/reactionmodel.h b/src/models/reactionmodel.h index acc602dc3..c866bd46a 100644 --- a/src/models/reactionmodel.h +++ b/src/models/reactionmodel.h @@ -36,7 +36,7 @@ public: HasLocalUser, /**< Whether the local user is in the list of authors. */ }; - ReactionModel(QObject *parent = nullptr, QList reactions = {}, NeoChatUser *localUser = nullptr); + explicit ReactionModel(QObject *parent = nullptr, QList reactions = {}, NeoChatUser *localUser = nullptr); /** * @brief Get the given role value at the given index. diff --git a/src/neochatuser.h b/src/neochatuser.h index 797b33909..c9e96d1d9 100644 --- a/src/neochatuser.h +++ b/src/neochatuser.h @@ -23,7 +23,7 @@ class NeoChatUser : public Quotient::User */ Q_PROPERTY(QColor color READ color WRITE setColor NOTIFY colorChanged) public: - NeoChatUser(QString userId, Quotient::Connection *connection); + explicit NeoChatUser(QString userId, Quotient::Connection *connection); public Q_SLOTS: QColor color();