Hyprland/src/debug/HyprCtl.hpp

26 lines
650 B
C++
Raw Normal View History

2022-03-20 16:51:14 +01:00
#pragma once
#include "../Compositor.hpp"
#include <fstream>
2022-04-04 19:44:25 +02:00
#include "../helpers/MiscFunctions.hpp"
2022-03-20 16:51:14 +01:00
namespace HyprCtl {
void startHyprCtlSocket();
std::string makeDynamicCall(const std::string& input);
2022-03-20 16:51:14 +01:00
2022-04-21 22:00:03 +02:00
// very simple thread-safe request method
inline bool requestMade = false;
inline bool requestReady = false;
inline std::string request = "";
2022-04-21 22:00:03 +02:00
inline std::ifstream requestStream;
2022-09-10 21:21:28 +02:00
inline wl_event_source* hyprCtlTickSource = nullptr;
inline int iSocketFD = -1;
enum eHyprCtlOutputFormat {
FORMAT_NORMAL = 0,
FORMAT_JSON
};
2022-03-20 16:51:14 +01:00
};