You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
46 lines
1.2 KiB
C++
46 lines
1.2 KiB
C++
/*---------------------------------------------------------*\
|
|
| SuspendResume_Linux_FreeBSD.h |
|
|
| |
|
|
| Suspend/resume Linux/FreeBSD implementation |
|
|
| |
|
|
| Zach Deibert (zachdeibert) 12 Nov 2024 |
|
|
| |
|
|
| This file is part of the OpenRGB project |
|
|
| SPDX-License-Identifier: GPL-2.0-or-later |
|
|
\*---------------------------------------------------------*/
|
|
|
|
#pragma once
|
|
|
|
#include <QDBusConnection>
|
|
#include <QObject>
|
|
#include "SuspendResume.h"
|
|
|
|
class SuspendResumeListener;
|
|
|
|
class SuspendResumeLoginManager : public QObject
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
SuspendResumeLoginManager(SuspendResumeListener *srl);
|
|
~SuspendResumeLoginManager();
|
|
|
|
public slots:
|
|
void PrepareForSleep(bool mode);
|
|
|
|
private:
|
|
SuspendResumeListener *srl;
|
|
QDBusConnection bus;
|
|
};
|
|
|
|
class SuspendResumeListener : public SuspendResumeListenerBase
|
|
{
|
|
friend class SuspendResumeLoginManager;
|
|
|
|
protected:
|
|
SuspendResumeListener();
|
|
|
|
private:
|
|
SuspendResumeLoginManager login_manager;
|
|
};
|