From a467247f083e7005a92783658f62ebc34b126db7 Mon Sep 17 00:00:00 2001 From: Albert Vaca Cintora Date: Tue, 8 Aug 2023 20:23:25 +0200 Subject: [PATCH] Only use proxy signals for Q_PROPERTY NOTIFY In other cases we can just connect to the signal from the parent class --- indicator/main.cpp | 2 +- interfaces/dbusinterfaces.h | 2 -- kcm/kcm.cpp | 2 +- 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/indicator/main.cpp b/indicator/main.cpp index 053e7dd6f..7b1331862 100644 --- a/indicator/main.cpp +++ b/indicator/main.cpp @@ -139,7 +139,7 @@ int main(int argc, char **argv) #endif }; - QObject::connect(&iface, &DaemonDbusInterface::pairingRequestsChangedProxy, &model, refreshMenu); + QObject::connect(&iface, &DaemonDbusInterface::pairingRequestsChanged, &model, refreshMenu); QObject::connect(&model, &DevicesModel::rowsInserted, &model, refreshMenu); QObject::connect(&model, &DevicesModel::rowsRemoved, &model, refreshMenu); diff --git a/interfaces/dbusinterfaces.h b/interfaces/dbusinterfaces.h index ade41ede7..69a483ef6 100644 --- a/interfaces/dbusinterfaces.h +++ b/interfaces/dbusinterfaces.h @@ -45,8 +45,6 @@ public: static QString activatedService(); Q_SIGNALS: - void deviceAdded(const QString &id); - void pairingRequestsChangedProxy(); void customDevicesChangedProxy(); }; diff --git a/kcm/kcm.cpp b/kcm/kcm.cpp index 876e71ffb..64c7a013d 100644 --- a/kcm/kcm.cpp +++ b/kcm/kcm.cpp @@ -166,7 +166,7 @@ void KdeConnectKcm::deviceSelected(const QModelIndex ¤t) connect(currentDevice, SIGNAL(pluginsChanged()), this, SLOT(resetCurrentDevice())); connect(currentDevice, SIGNAL(pairingFailed(QString)), this, SLOT(pairingFailed(QString))); - connect(currentDevice, &DeviceDbusInterface::pairStateChangedProxy, this, &KdeConnectKcm::setCurrentDevicePairState); + connect(currentDevice, &DeviceDbusInterface::pairStateChanged, this, &KdeConnectKcm::setCurrentDevicePairState); } void KdeConnectKcm::resetCurrentDevice()