mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-22 00:17:23 -06:00
Disable copy, move constructors when inheriting from QObject
This commit is contained in:
@@ -43,6 +43,7 @@ namespace Net
|
||||
class DNSUpdater : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY_MOVE(DNSUpdater)
|
||||
|
||||
public:
|
||||
explicit DNSUpdater(QObject *parent = nullptr);
|
||||
|
||||
@@ -50,6 +50,7 @@ namespace Net
|
||||
class Smtp : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY_MOVE(Smtp)
|
||||
|
||||
public:
|
||||
Smtp(QObject *parent = nullptr);
|
||||
|
||||
@@ -94,11 +94,6 @@ class Preferences : public QObject
|
||||
|
||||
Preferences();
|
||||
|
||||
static Preferences *m_instance;
|
||||
|
||||
signals:
|
||||
void changed();
|
||||
|
||||
public:
|
||||
static void initInstance();
|
||||
static void freeInstance();
|
||||
@@ -414,4 +409,10 @@ public slots:
|
||||
void setTrackerFilterState(bool checked);
|
||||
|
||||
void apply();
|
||||
|
||||
signals:
|
||||
void changed();
|
||||
|
||||
private:
|
||||
static Preferences *m_instance;
|
||||
};
|
||||
|
||||
@@ -52,6 +52,7 @@ namespace RSS
|
||||
class Parser : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY_MOVE(Parser)
|
||||
|
||||
public:
|
||||
explicit Parser(QString lastBuildDate);
|
||||
|
||||
@@ -53,6 +53,8 @@ struct IsQFlags<QFlags<T>> : std::true_type {};
|
||||
class SettingsStorage final : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DISABLE_COPY_MOVE(SettingsStorage)
|
||||
|
||||
SettingsStorage();
|
||||
~SettingsStorage();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user