// SPDX-FileCopyrightText: 2018 - 2023 UnionTech Software Technology Co., Ltd. // // SPDX-License-Identifier: GPL-3.0-or-later #ifndef DBUSADAPTORENTRY_H #define DBUSADAPTORENTRY_H #include "entry.h" #include "windowinfomap.h" #include #include #include #include #include #include #include #include #include #include #include /* * Adaptor class for interface org.deepin.dde.daemon.Dock1.Entry */ class DBusAdaptorEntry: public QDBusAbstractAdaptor { Q_OBJECT Q_CLASSINFO("D-Bus Interface", "org.deepin.dde.daemon.Dock1.Entry") Q_CLASSINFO("D-Bus Introspection", "" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" " \n" "") public: explicit DBusAdaptorEntry(QObject *parent); virtual ~DBusAdaptorEntry(); public: // PROPERTIES Q_PROPERTY(uint CurrentWindow READ currentWindow NOTIFY CurrentWindowChanged) uint currentWindow() const; Q_PROPERTY(QString DesktopFile READ desktopFile NOTIFY DesktopFileChanged) QString desktopFile() const; Q_PROPERTY(QString Icon READ icon NOTIFY IconChanged) QString icon() const; Q_PROPERTY(QString Id READ id) QString id() const; Q_PROPERTY(bool IsActive READ isActive NOTIFY IsActiveChanged) bool isActive() const; Q_PROPERTY(bool IsDocked READ isDocked NOTIFY IsDockedChanged) bool isDocked() const; Q_PROPERTY(QString Menu READ menu NOTIFY MenuChanged) QString menu() const; Q_PROPERTY(QString Name READ name NOTIFY NameChanged) QString name() const; Q_PROPERTY(WindowInfoMap WindowInfos READ windowInfos NOTIFY WindowInfosChanged) WindowInfoMap windowInfos(); Q_PROPERTY(int Mode READ mode NOTIFY ModeChanged) int mode() const; Entry *parent() const; public Q_SLOTS: // METHODS void Activate(uint timestamp); void Check(); void ForceQuit(); void ActiveWindow(quint32 winId); QList GetAllowedCloseWindows(); void HandleDragDrop(uint timestamp, const QStringList &files); void HandleMenuItem(uint timestamp, const QString &id); void NewInstance(uint timestamp); void PresentWindows(); void RequestDock(); void RequestUndock(); Q_SIGNALS: // SIGNALS void IsActiveChanged(bool value) const; void IsDockedChanged(bool value) const; void MenuChanged(const QString &value) const; void IconChanged(const QString &value) const; void NameChanged(const QString &value) const; void DesktopFileChanged(const QString &value) const; void CurrentWindowChanged(uint32_t value) const; void WindowInfosChanged(WindowInfoMap value) const; void ModeChanged(int value) const; }; #endif