// SPDX-FileCopyrightText: 2023 Devin Lin // SPDX-License-Identifier: GPL-2.0-or-later #pragma once #include #include #include #include #include class LockscreenDBusClient : public QObject { Q_OBJECT QML_ELEMENT QML_SINGLETON Q_PROPERTY(bool lockscreenActive READ lockscreenActive NOTIFY lockscreenActiveChanged); public: explicit LockscreenDBusClient(QObject *parent = nullptr); bool lockscreenActive() const; Q_SIGNALS: void lockscreenActiveChanged(); void lockscreenUnlocked(); void lockscreenLocked(); public Q_SLOTS: void slotLockscreenActiveChanged(bool active); void dbusError(QDBusError error); private: bool m_lockscreenActive = false; bool m_firstPropertySet = false; };