File indexing completed on 2024-04-21 16:11:00

0001 /*
0002     SPDX-FileCopyrightText: 2022 Aditya Mehra <aix.m@outlook.com>
0003     SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0004 */
0005 
0006 #ifndef CONTROLLERMANAGERDBUSINTERFACE_H
0007 #define CONTROLLERMANAGERDBUSINTERFACE_H
0008 
0009 #include <QObject>
0010 #include "controllermanager.h"
0011 
0012 class ControllerManagerDBusInterface : public QObject
0013 {
0014     Q_OBJECT
0015     Q_CLASSINFO("D-Bus Interface", "org.kde.plasma.remotecontrollers.ControllerManager")
0016     
0017 public:
0018     explicit ControllerManagerDBusInterface(QObject *parent = nullptr);
0019     ~ControllerManagerDBusInterface() override;
0020 
0021 public Q_SLOTS:
0022     Q_SCRIPTABLE QStringList connectedDevices();
0023     Q_SCRIPTABLE QString deviceName(const QString &uniqueIdentifier);
0024     Q_SCRIPTABLE int deviceType(const QString &uniqueIdentifier);
0025     Q_SCRIPTABLE QString deviceIconName(const QString &uniqueIdentifier);
0026     Q_SCRIPTABLE void acquireNoOp();
0027     Q_SCRIPTABLE void releaseNoOp();
0028 
0029 Q_SIGNALS:
0030     void deviceConnected(const QString &uniqueIdentifier);
0031     void deviceDisconnected(const QString &uniqueIdentifier);
0032 };
0033 
0034 #endif // CONTROLLERMANAGERDBUSINTERFACE_H