2022-12-05 18:05:15 +01:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "../defines.hpp"
|
2024-07-27 17:02:02 +02:00
|
|
|
#include "../helpers/Monitor.hpp"
|
2024-06-11 17:17:45 +02:00
|
|
|
#include "../helpers/memory/Memory.hpp"
|
|
|
|
#include "../helpers/signal/Signal.hpp"
|
2024-06-09 22:28:51 +02:00
|
|
|
#include <unordered_map>
|
2022-12-05 18:05:15 +01:00
|
|
|
|
|
|
|
class CProtocolManager {
|
2022-12-16 18:17:31 +01:00
|
|
|
public:
|
2022-12-05 18:05:15 +01:00
|
|
|
CProtocolManager();
|
2024-07-24 19:07:36 +02:00
|
|
|
~CProtocolManager();
|
2022-12-05 18:05:15 +01:00
|
|
|
|
2024-10-06 15:07:07 +02:00
|
|
|
bool isGlobalPrivileged(const wl_global* global);
|
|
|
|
|
2024-06-09 22:28:51 +02:00
|
|
|
private:
|
|
|
|
std::unordered_map<std::string, CHyprSignalListener> m_mModeChangeListeners;
|
|
|
|
|
|
|
|
void onMonitorModeChange(CMonitor* pMonitor);
|
2022-12-05 18:05:15 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
inline std::unique_ptr<CProtocolManager> g_pProtocolManager;
|