File indexing completed on 2024-06-23 05:29:05

0001 /*
0002     SPDX-FileCopyrightText: 2016 Aditya Mehra <aix.m@outlook.com>
0003     SPDX-License-Identifier: LGPL-2.0-or-later
0004 */
0005 
0006 #ifndef BIGLAUNCHER_DBUS_H
0007 #define BIGLAUNCHER_DBUS_H
0008 
0009 #include "biglauncherhomescreen.h"
0010 #include <QObject>
0011 #include <QStringList>
0012 #include <QtDBus>
0013 
0014 QT_BEGIN_NAMESPACE
0015 class QByteArray;
0016 template<class T>
0017 class QList;
0018 template<class Key, class Value>
0019 class QMap;
0020 class QString;
0021 class QVariant;
0022 QT_END_NAMESPACE
0023 
0024 /*
0025  * Adaptor class for interface org.kde.biglauncher
0026  */
0027 class BigLauncherDbusAdapterInterface : public QDBusAbstractAdaptor
0028 {
0029     Q_OBJECT
0030     Q_CLASSINFO("D-Bus Interface", "org.kde.biglauncher")
0031     Q_CLASSINFO("D-Bus Introspection",
0032                 ""
0033                 "  <interface name=\"org.kde.biglauncher\">\n"
0034                 "    <signal name=\"useColoredTilesChanged\">\n"
0035                 "      <arg direction=\"out\" type=\"b\" name=\"msgUseColoredTiles\"/>\n"
0036                 "    </signal>\n"
0037                 "    <signal name=\"useExpandableTilesChanged\">\n"
0038                 "      <arg direction=\"out\" type=\"b\" name=\"msgUseExpandableTiles\"/>\n"
0039                 "    </signal>\n"
0040                 "    <signal name=\"enableMycroftIntegrationChanged\">\n"
0041                 "      <arg direction=\"out\" type=\"b\" name=\"msgEnableMycroftIntegration\"/>\n"
0042                 "    </signal>\n"
0043                 "    <signal name=\"enablePmInhibitionChanged\">\n"
0044                 "      <arg direction=\"out\" type=\"b\" name=\"msgEnablePmInhibition\"/>\n"
0045                 "    </signal>\n"
0046                 "    <method name=\"useColoredTiles\">\n"
0047                 "      <arg direction=\"in\" type=\"b\" name=\"coloredTiles\"/>\n"
0048                 "    </method>\n"
0049                 "    <method name=\"useExpandableTiles\">\n"
0050                 "      <arg direction=\"in\" type=\"b\" name=\"expandableTiles\"/>\n"
0051                 "    </method>\n"
0052                 "    <method name=\"enableMycroftIntegration\">\n"
0053                 "      <arg direction=\"in\" type=\"b\" name=\"mycroftIntegration\"/>\n"
0054                 "    </method>\n"
0055                 "    <method name=\"enablePmInhibition\">\n"
0056                 "      <arg direction=\"in\" type=\"b\" name=\"pmInhibition\"/>\n"
0057                 "    </method>\n"
0058                 "    <method name=\"coloredTilesActive\">\n"
0059                 "      <arg direction=\"out\" type=\"b\"/>\n"
0060                 "    </method>\n"
0061                 "    <method name=\"expandableTilesActive\">\n"
0062                 "      <arg direction=\"out\" type=\"b\"/>\n"
0063                 "    </method>\n"
0064                 "    <method name=\"mycroftIntegrationActive\">\n"
0065                 "      <arg direction=\"out\" type=\"b\"/>\n"
0066                 "    </method>\n"
0067                 "    <method name=\"pmInhibitionActive\">\n"
0068                 "      <arg direction=\"out\" type=\"b\"/>\n"
0069                 "    </method>\n"
0070                 "  </interface>\n"
0071                 "")
0072 public:
0073     BigLauncherDbusAdapterInterface(QObject *parent);
0074     virtual ~BigLauncherDbusAdapterInterface();
0075     Q_INVOKABLE QString getMethod(const QString &method);
0076 
0077 public: // PROPERTIES
0078 public Q_SLOTS: // METHODS
0079     void useColoredTiles(const bool &coloredTiles);
0080     void useExpandableTiles(const bool &expandableTiles);
0081     void enableMycroftIntegration(const bool &mycroftIntegration);
0082     bool coloredTilesActive();
0083     bool expandableTilesActive();
0084     bool mycroftIntegrationActive();
0085     bool pmInhibitionActive();
0086     void enablePmInhibition(const bool &pmInhibition);
0087 
0088     void setColoredTilesActive(const bool &coloredTilesActive);
0089     void setExpandableTilesActive(const bool &expandableTilesActive);
0090 
0091 Q_SIGNALS: // SIGNALS
0092     void useColoredTilesChanged(const bool &msgUseColoredTiles);
0093     void useExpandableTilesChanged(const bool &msgUseExpandableTiles);
0094     void enableMycroftIntegrationChanged(const bool &msgEnableMycroftIntegration);
0095     void enablePmInhibitionChanged(const bool &msgEnablePmInhibition);
0096     void coloredTilesActiveRequested();
0097     void expandableTilesActiveRequested();
0098     void enableMycroftIntegrationRequested();
0099 
0100 private:
0101     bool m_useColoredTiles;
0102     bool m_useExpandableTiles;
0103 };
0104 
0105 #endif