File indexing completed on 2024-02-25 05:56:44

0001 /*
0002     SPDX-FileCopyrightText: 2018 Harald Sitter <sitter@kde.org>
0003     SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0004 */
0005 
0006 #pragma once
0007 
0008 #include <QObject>
0009 
0010 class DBusInterface : public QObject
0011 {
0012     Q_OBJECT
0013     Q_CLASSINFO("D-Bus Interface", "org.kde.DistroReleaseNotifier")
0014     Q_PROPERTY(bool UseDevel READ useDevel WRITE setUseDevel NOTIFY useDevelChanged)
0015 public:
0016     DBusInterface(QObject *parent = nullptr);
0017 
0018     bool useDevel() const;
0019     void setUseDevel(bool use);
0020 
0021     Q_SCRIPTABLE void Poll();
0022 
0023 signals:
0024     void useDevelChanged();
0025     // Emitted when Poll is called to notify of the request
0026     void pollingRequested();
0027 
0028 private:
0029     bool m_useDevel;
0030 };