mirror of
https://repo.dec05eba.com/gpu-screen-recorder-ui
synced 2026-05-07 23:20:26 +09:00
Re-add kwin and hyprland helper to get window title, this time without a thread
This commit is contained in:
21
include/DesktopEnvironment/DesktopEnvironmentX11.hpp
Normal file
21
include/DesktopEnvironment/DesktopEnvironmentX11.hpp
Normal file
@@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
|
||||
#include "DesktopEnvironment.hpp"
|
||||
#include <X11/Xlib.h>
|
||||
|
||||
namespace gsr {
|
||||
class DesktopEnvironmentX11 : public DesktopEnvironment {
|
||||
public:
|
||||
DesktopEnvironmentX11(Display *dpy) : dpy(dpy) {}
|
||||
DesktopEnvironmentX11(const DesktopEnvironmentX11&) = delete;
|
||||
DesktopEnvironmentX11& operator=(const DesktopEnvironmentX11&) = delete;
|
||||
~DesktopEnvironmentX11();
|
||||
|
||||
bool start() override;
|
||||
void update() override;
|
||||
std::string get_focused_window_title() override;
|
||||
//std::string get_focused_monitor_name() override;
|
||||
private:
|
||||
Display *dpy = NULL;
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user