diff --git a/plugins/bigscreen/bigscreenplugin.cpp b/plugins/bigscreen/bigscreenplugin.cpp index 8406361f3..31b957e42 100644 --- a/plugins/bigscreen/bigscreenplugin.cpp +++ b/plugins/bigscreen/bigscreenplugin.cpp @@ -20,11 +20,6 @@ K_PLUGIN_CLASS_WITH_JSON(BigscreenPlugin, "kdeconnect_bigscreen.json") Q_LOGGING_CATEGORY(KDECONNECT_PLUGIN_BIGSCREEN, "kdeconnect.plugin.bigscreen") -BigscreenPlugin::BigscreenPlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - bool BigscreenPlugin::receivePacket(const NetworkPacket &np) { QString message = np.get(QStringLiteral("content")); diff --git a/plugins/bigscreen/bigscreenplugin.h b/plugins/bigscreen/bigscreenplugin.h index d97ba7d99..f05e4ebf7 100644 --- a/plugins/bigscreen/bigscreenplugin.h +++ b/plugins/bigscreen/bigscreenplugin.h @@ -17,8 +17,7 @@ class BigscreenPlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.bigscreen") public: - explicit BigscreenPlugin(QObject *parent, const QVariantList &args); - + using KdeConnectPlugin::KdeConnectPlugin; bool receivePacket(const NetworkPacket &np) override; QString dbusPath() const override; diff --git a/plugins/connectivity-report/connectivity_reportplugin.cpp b/plugins/connectivity-report/connectivity_reportplugin.cpp index 4a183dd37..8b2eb9a3b 100644 --- a/plugins/connectivity-report/connectivity_reportplugin.cpp +++ b/plugins/connectivity-report/connectivity_reportplugin.cpp @@ -15,11 +15,6 @@ K_PLUGIN_CLASS_WITH_JSON(ConnectivityReportPlugin, "kdeconnect_connectivity_report.json") -ConnectivityReportPlugin::ConnectivityReportPlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - QString ConnectivityReportPlugin::cellularNetworkType() const { return m_cellularNetworkType; diff --git a/plugins/connectivity-report/connectivity_reportplugin.h b/plugins/connectivity-report/connectivity_reportplugin.h index 13a601a9a..9bc554f78 100644 --- a/plugins/connectivity-report/connectivity_reportplugin.h +++ b/plugins/connectivity-report/connectivity_reportplugin.h @@ -39,7 +39,7 @@ class ConnectivityReportPlugin : public KdeConnectPlugin Q_PROPERTY(int cellularNetworkStrength READ cellularNetworkStrength NOTIFY refreshed) public: - explicit ConnectivityReportPlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; bool receivePacket(const NetworkPacket &np) override; QString dbusPath() const override; diff --git a/plugins/findmyphone/findmyphoneplugin.cpp b/plugins/findmyphone/findmyphoneplugin.cpp index 81139f069..53f9ac1f1 100644 --- a/plugins/findmyphone/findmyphoneplugin.cpp +++ b/plugins/findmyphone/findmyphoneplugin.cpp @@ -14,11 +14,6 @@ K_PLUGIN_CLASS_WITH_JSON(FindMyPhonePlugin, "kdeconnect_findmyphone.json") -FindMyPhonePlugin::FindMyPhonePlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - bool FindMyPhonePlugin::receivePacket(const NetworkPacket & /*np*/) { return false; diff --git a/plugins/findmyphone/findmyphoneplugin.h b/plugins/findmyphone/findmyphoneplugin.h index 89c7be0b4..722d5cb6a 100644 --- a/plugins/findmyphone/findmyphoneplugin.h +++ b/plugins/findmyphone/findmyphoneplugin.h @@ -18,7 +18,7 @@ class FindMyPhonePlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.findmyphone") public: - explicit FindMyPhonePlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; Q_SCRIPTABLE void ring(); diff --git a/plugins/findthisdevice/findthisdeviceplugin.cpp b/plugins/findthisdevice/findthisdeviceplugin.cpp index b195677e1..0fbbab778 100644 --- a/plugins/findthisdevice/findthisdeviceplugin.cpp +++ b/plugins/findthisdevice/findthisdeviceplugin.cpp @@ -26,11 +26,6 @@ K_PLUGIN_CLASS_WITH_JSON(FindThisDevicePlugin, "kdeconnect_findthisdevice.json") -FindThisDevicePlugin::FindThisDevicePlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - bool FindThisDevicePlugin::receivePacket(const NetworkPacket & /*np*/) { const QString soundFile = config()->getString(QStringLiteral("ringtone"), defaultSound()); diff --git a/plugins/findthisdevice/findthisdeviceplugin.h b/plugins/findthisdevice/findthisdeviceplugin.h index 366087bbe..a5678b7b7 100644 --- a/plugins/findthisdevice/findthisdeviceplugin.h +++ b/plugins/findthisdevice/findthisdeviceplugin.h @@ -27,7 +27,7 @@ class FindThisDevicePlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.findthisdevice") public: - explicit FindThisDevicePlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; QString dbusPath() const override; bool receivePacket(const NetworkPacket &np) override; diff --git a/plugins/mprisremote/mprisremoteplugin.cpp b/plugins/mprisremote/mprisremoteplugin.cpp index ea4f5c47a..5ebe17390 100644 --- a/plugins/mprisremote/mprisremoteplugin.cpp +++ b/plugins/mprisremote/mprisremoteplugin.cpp @@ -16,11 +16,6 @@ K_PLUGIN_CLASS_WITH_JSON(MprisRemotePlugin, "kdeconnect_mprisremote.json") -MprisRemotePlugin::MprisRemotePlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - bool MprisRemotePlugin::receivePacket(const NetworkPacket &np) { if (np.type() != PACKET_TYPE_MPRIS) diff --git a/plugins/mprisremote/mprisremoteplugin.h b/plugins/mprisremote/mprisremoteplugin.h index 86c394d47..9de8b20a0 100644 --- a/plugins/mprisremote/mprisremoteplugin.h +++ b/plugins/mprisremote/mprisremoteplugin.h @@ -31,7 +31,7 @@ class MprisRemotePlugin : public KdeConnectPlugin Q_PROPERTY(bool canSeek READ canSeek NOTIFY propertiesChanged) public: - explicit MprisRemotePlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; long position() const; int volume() const; diff --git a/plugins/notifications/notificationsplugin.cpp b/plugins/notifications/notificationsplugin.cpp index bb5d840c2..18c8a2994 100644 --- a/plugins/notifications/notificationsplugin.cpp +++ b/plugins/notifications/notificationsplugin.cpp @@ -22,11 +22,6 @@ K_PLUGIN_CLASS_WITH_JSON(NotificationsPlugin, "kdeconnect_notifications.json") -NotificationsPlugin::NotificationsPlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - void NotificationsPlugin::connected() { NetworkPacket np(PACKET_TYPE_NOTIFICATION_REQUEST, {{QStringLiteral("request"), true}}); diff --git a/plugins/notifications/notificationsplugin.h b/plugins/notifications/notificationsplugin.h index 2dfc72ee9..0a4d5f884 100644 --- a/plugins/notifications/notificationsplugin.h +++ b/plugins/notifications/notificationsplugin.h @@ -20,7 +20,7 @@ class NotificationsPlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.notifications") public: - explicit NotificationsPlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; bool receivePacket(const NetworkPacket &np) override; void connected() override; diff --git a/plugins/photo/photoplugin.cpp b/plugins/photo/photoplugin.cpp index 6593aa4d6..2f3a97cdb 100644 --- a/plugins/photo/photoplugin.cpp +++ b/plugins/photo/photoplugin.cpp @@ -15,11 +15,6 @@ K_PLUGIN_CLASS_WITH_JSON(PhotoPlugin, "kdeconnect_photo.json") -PhotoPlugin::PhotoPlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - bool PhotoPlugin::receivePacket(const NetworkPacket &np) { if (np.get(QStringLiteral("cancel"))) { diff --git a/plugins/photo/photoplugin.h b/plugins/photo/photoplugin.h index 23984e096..769cf4373 100644 --- a/plugins/photo/photoplugin.h +++ b/plugins/photo/photoplugin.h @@ -19,7 +19,7 @@ class PhotoPlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.photo") public: - explicit PhotoPlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; Q_SCRIPTABLE void requestPhoto(const QString &url); diff --git a/plugins/ping/pingplugin.cpp b/plugins/ping/pingplugin.cpp index 9c8bc5944..87fe2bd19 100644 --- a/plugins/ping/pingplugin.cpp +++ b/plugins/ping/pingplugin.cpp @@ -19,17 +19,6 @@ K_PLUGIN_CLASS_WITH_JSON(PingPlugin, "kdeconnect_ping.json") -PingPlugin::PingPlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ - // qCDebug(KDECONNECT_PLUGIN_PING) << "Ping plugin constructor for device" << device()->name(); -} - -PingPlugin::~PingPlugin() -{ - // qCDebug(KDECONNECT_PLUGIN_PING) << "Ping plugin destructor for device" << device()->name(); -} - bool PingPlugin::receivePacket(const NetworkPacket &np) { Daemon::instance()->sendSimpleNotification(QStringLiteral("pingReceived"), diff --git a/plugins/ping/pingplugin.h b/plugins/ping/pingplugin.h index 70590deeb..5b3c5c086 100644 --- a/plugins/ping/pingplugin.h +++ b/plugins/ping/pingplugin.h @@ -18,8 +18,7 @@ class PingPlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.ping") public: - explicit PingPlugin(QObject *parent, const QVariantList &args); - ~PingPlugin() override; + using KdeConnectPlugin::KdeConnectPlugin; Q_SCRIPTABLE void sendPing(); Q_SCRIPTABLE void sendPing(const QString &customMessage); diff --git a/plugins/remotecontrol/remotecontrolplugin.cpp b/plugins/remotecontrol/remotecontrolplugin.cpp index b2d7b36b6..28418d2bd 100644 --- a/plugins/remotecontrol/remotecontrolplugin.cpp +++ b/plugins/remotecontrol/remotecontrolplugin.cpp @@ -18,11 +18,6 @@ K_PLUGIN_CLASS_WITH_JSON(RemoteControlPlugin, "kdeconnect_remotecontrol.json") -RemoteControlPlugin::RemoteControlPlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - void RemoteControlPlugin::moveCursor(const QPoint &p) { NetworkPacket np(PACKET_TYPE_MOUSEPAD_REQUEST, {{QStringLiteral("dx"), p.x()}, {QStringLiteral("dy"), p.y()}}); diff --git a/plugins/remotecontrol/remotecontrolplugin.h b/plugins/remotecontrol/remotecontrolplugin.h index caeac0b2f..4dfc683d5 100644 --- a/plugins/remotecontrol/remotecontrolplugin.h +++ b/plugins/remotecontrol/remotecontrolplugin.h @@ -18,7 +18,7 @@ class RemoteControlPlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.remotecontrol") public: - explicit RemoteControlPlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; bool receivePacket(const NetworkPacket & /*np*/) override { diff --git a/plugins/remotesystemvolume/remotesystemvolumeplugin.cpp b/plugins/remotesystemvolume/remotesystemvolumeplugin.cpp index a57c9bfc0..08f572207 100644 --- a/plugins/remotesystemvolume/remotesystemvolumeplugin.cpp +++ b/plugins/remotesystemvolume/remotesystemvolumeplugin.cpp @@ -21,11 +21,6 @@ K_PLUGIN_CLASS_WITH_JSON(RemoteSystemVolumePlugin, "kdeconnect_remotesystemvolume.json") -RemoteSystemVolumePlugin::RemoteSystemVolumePlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - bool RemoteSystemVolumePlugin::receivePacket(const NetworkPacket &np) { if (np.has(QStringLiteral("sinkList"))) { diff --git a/plugins/remotesystemvolume/remotesystemvolumeplugin.h b/plugins/remotesystemvolume/remotesystemvolumeplugin.h index 424249087..822eb88c8 100644 --- a/plugins/remotesystemvolume/remotesystemvolumeplugin.h +++ b/plugins/remotesystemvolume/remotesystemvolumeplugin.h @@ -21,7 +21,7 @@ class RemoteSystemVolumePlugin : public KdeConnectPlugin Q_PROPERTY(QString deviceId READ deviceId CONSTANT) public: - explicit RemoteSystemVolumePlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; bool receivePacket(const NetworkPacket &np) override; void connected() override; diff --git a/plugins/telephony/telephonyplugin.cpp b/plugins/telephony/telephonyplugin.cpp index 5d03e2db1..f94f7ef83 100644 --- a/plugins/telephony/telephonyplugin.cpp +++ b/plugins/telephony/telephonyplugin.cpp @@ -17,11 +17,6 @@ K_PLUGIN_CLASS_WITH_JSON(TelephonyPlugin, "kdeconnect_telephony.json") -TelephonyPlugin::TelephonyPlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - void TelephonyPlugin::createNotification(const NetworkPacket &np) { const QString event = np.get(QStringLiteral("event")); diff --git a/plugins/telephony/telephonyplugin.h b/plugins/telephony/telephonyplugin.h index dbae07413..4bc77b22c 100644 --- a/plugins/telephony/telephonyplugin.h +++ b/plugins/telephony/telephonyplugin.h @@ -35,7 +35,7 @@ class TelephonyPlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.telephony") public: - explicit TelephonyPlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; bool receivePacket(const NetworkPacket &np) override; QString dbusPath() const override; diff --git a/plugins/virtualmonitor/virtualmonitorplugin.cpp b/plugins/virtualmonitor/virtualmonitorplugin.cpp index 42b85fac4..2808e2019 100644 --- a/plugins/virtualmonitor/virtualmonitorplugin.cpp +++ b/plugins/virtualmonitor/virtualmonitorplugin.cpp @@ -19,11 +19,6 @@ K_PLUGIN_CLASS_WITH_JSON(VirtualMonitorPlugin, "kdeconnect_virtualmonitor.json") #define QS QLatin1String -VirtualMonitorPlugin::VirtualMonitorPlugin(QObject *parent, const QVariantList &args) - : KdeConnectPlugin(parent, args) -{ -} - VirtualMonitorPlugin::~VirtualMonitorPlugin() { stop(); diff --git a/plugins/virtualmonitor/virtualmonitorplugin.h b/plugins/virtualmonitor/virtualmonitorplugin.h index 3bab552ce..56535812d 100644 --- a/plugins/virtualmonitor/virtualmonitorplugin.h +++ b/plugins/virtualmonitor/virtualmonitorplugin.h @@ -21,7 +21,7 @@ class VirtualMonitorPlugin : public KdeConnectPlugin Q_CLASSINFO("D-Bus Interface", "org.kde.kdeconnect.device.virtualmonitor") public: - explicit VirtualMonitorPlugin(QObject *parent, const QVariantList &args); + using KdeConnectPlugin::KdeConnectPlugin; ~VirtualMonitorPlugin() override; Q_SCRIPTABLE bool requestVirtualMonitor();