From 355beb1bd55f31c01e36834afc3c1ac9621bfdb2 Mon Sep 17 00:00:00 2001 From: JeJo Date: Sat, 4 May 2019 22:32:13 +0200 Subject: [PATCH] ScreenPlay Q_DISABLE_COPY_MOVE() macro fix --- ScreenPlay/src/screenplay.h | 6 ++++-- ScreenPlay/src/screenplaywallpaper.h | 4 +++- ScreenPlay/src/screenplaywidget.h | 5 ++++- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/ScreenPlay/src/screenplay.h b/ScreenPlay/src/screenplay.h index 8ac867d2..19be9983 100644 --- a/ScreenPlay/src/screenplay.h +++ b/ScreenPlay/src/screenplay.h @@ -45,8 +45,10 @@ public: MonitorListModel* mlm, SDKConnector* sdkc, QObject* parent = nullptr); - // copy and move disable(for now) : remember rule of 1/3/5 - Q_DISABLE_COPY_MOVE(ScreenPlay) + // copy and move disabled(for now) : remember rule of 1/3/5 + Q_DISABLE_COPY(ScreenPlay) + ScreenPlay(ScreenPlay&&) = delete; + ScreenPlay& operator=(ScreenPlay&&) = delete; // destructor ~ScreenPlay(); diff --git a/ScreenPlay/src/screenplaywallpaper.h b/ScreenPlay/src/screenplaywallpaper.h index a2e3d8cf..21efdbe2 100644 --- a/ScreenPlay/src/screenplaywallpaper.h +++ b/ScreenPlay/src/screenplaywallpaper.h @@ -37,7 +37,9 @@ public: const QString& type, ScreenPlay* parent = nullptr); // copy and move disable(for now) : remember rule of 1/3/5 - Q_DISABLE_COPY_MOVE(ScreenPlayWallpaper) + Q_DISABLE_COPY(ScreenPlayWallpaper) + ScreenPlayWallpaper(ScreenPlayWallpaper&& rhs); + ScreenPlayWallpaper& operator=(ScreenPlayWallpaper&& rhs); // destructor ~ScreenPlayWallpaper(); diff --git a/ScreenPlay/src/screenplaywidget.h b/ScreenPlay/src/screenplaywidget.h index adefbe5e..262da31f 100644 --- a/ScreenPlay/src/screenplaywidget.h +++ b/ScreenPlay/src/screenplaywidget.h @@ -32,7 +32,10 @@ public: const QString& fullPath, ScreenPlay* parent = nullptr); // copy and move disable(for now) : remember rule of 1/3/5 - Q_DISABLE_COPY_MOVE(ScreenPlayWidget) + //Q_DISABLE_COPY_MOVE(ScreenPlayWidget) + Q_DISABLE_COPY(ScreenPlayWidget) + ScreenPlayWidget(ScreenPlayWidget&&) = delete; + ScreenPlayWidget& operator=(ScreenPlayWidget&&) = delete; // destructor ~ScreenPlayWidget();