KUnifiedPush
kcmpushnotifications.cpp
25KCMPushNotifications::KCMPushNotifications(QObject *parent, const KPluginMetaData &data, [[maybe_unused]] const QVariantList &args)
33 m_nam.enableStrictTransportSecurityStore(true, QStandardPaths::writableLocation(QStandardPaths::GenericCacheLocation) + QLatin1String("/org.kde.kunifiedpush/hsts/"));
36 m_mgmtIface = new OrgKdeKunifiedpushManagementInterface(KDE_DISTRIBUTOR_SERVICE_NAME, KDE_DISTRIBUTOR_MANAGEMENT_PATH, QDBusConnection::sessionBus(), this);
37 connect(m_mgmtIface, &OrgKdeKunifiedpushManagementInterface::statusChanged, this, &KCMPushNotifications::distributorStatusChanged);
38 connect(m_mgmtIface, &OrgKdeKunifiedpushManagementInterface::errorMessageChanged, this, &KCMPushNotifications::distributorErrorMessageChanged);
39 connect(m_mgmtIface, &OrgKdeKunifiedpushManagementInterface::pushProviderChanged, this, &KCMPushNotifications::pushProviderChanged);
44 connect(&m_serviceWatcher, &QDBusServiceWatcher::serviceRegistered, this, &KCMPushNotifications::distributorChanged);
45 connect(&m_serviceWatcher, &QDBusServiceWatcher::serviceUnregistered, this, &KCMPushNotifications::distributorChanged);
47 m_serviceWatcher.setWatchMode(QDBusServiceWatcher::WatchForRegistration | QDBusServiceWatcher::WatchForUnregistration);
49 connect(this, &KCMPushNotifications::distributorChanged, this, &KCMPushNotifications::distributorStatusChanged);
50 connect(this, &KCMPushNotifications::distributorChanged, this, &KCMPushNotifications::pushProviderChanged);
55 qmlRegisterUncreatableMetaObject(DistributorStatus::staticMetaObject, "org.kde.kunifiedpush.kcm", 1, 0, "DistributorStatus", {});
56 qmlRegisterUncreatableMetaObject(SelfTest::staticMetaObject, "org.kde.kunifiedpush.kcm", 1, 0, "SelfTest", {});
101void KCMPushNotifications::setPushProviderConfiguration(const QString &pushProviderId, const QVariantMap &config)
118 connect(m_nextcloudAuthenticator.get(), &NextcloudAuthenticator::authenticated, this, &KCMPushNotifications::nextcloudAuthenticated);
120 m_nextcloudAuthenticator->authenticate(url, QStringLiteral("KUnifiedPush Distributor (%1)").arg(QHostInfo::localHostName()));
virtual void save()
#define K_PLUGIN_CLASS_WITH_JSON(classname, jsonFile)
QDBusConnection sessionBus()
WatchForRegistration
void serviceRegistered(const QString &serviceName)
void serviceUnregistered(const QString &serviceName)
QString localHostName()
NoLessSafeRedirectPolicy
Q_EMITQ_EMIT
QMetaObject::Connection connect(const QObject *sender, PointerToMemberFunction signal, Functor functor)
GenericCacheLocation
QString writableLocation(StandardLocation type)
QFuture< ArgsType< Signal > > connect(Sender *sender, Signal signal)
bool isValid() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Apr 18 2025 12:16:55 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Apr 18 2025 12:16:55 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.