aboutsummaryrefslogtreecommitdiff
path: root/include/WindowUtils.hpp
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2025-02-10 19:31:27 +0100
committerdec05eba <dec05eba@protonmail.com>2025-02-10 19:31:27 +0100
commitfc2f6f4c500d0364d5dd5cf366be2fa8592f8469 (patch)
treead8ffcab18e0aeca25abb4ea0f751f8bf12b7f8b /include/WindowUtils.hpp
parentf4e44cbef5dbbc2a2b71e7b9b70ee72d30b7c6a6 (diff)
Better detect focused x11 window on wayland, properly get focused game name on wayland
Diffstat (limited to 'include/WindowUtils.hpp')
-rw-r--r--include/WindowUtils.hpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/WindowUtils.hpp b/include/WindowUtils.hpp
index ddecaea..99b45e9 100644
--- a/include/WindowUtils.hpp
+++ b/include/WindowUtils.hpp
@@ -3,6 +3,7 @@
#include <mglpp/system/vec.hpp>
#include <string>
#include <vector>
+#include <optional>
#include <X11/Xlib.h>
namespace gsr {
@@ -16,6 +17,7 @@ namespace gsr {
mgl::vec2i size;
};
+ std::optional<std::string> get_window_title(Display *dpy, Window window);
Window get_focused_window(Display *dpy, WindowCaptureType cap_type);
std::string get_focused_window_name(Display *dpy, WindowCaptureType window_capture_type);
std::string get_window_name_at_position(Display *dpy, mgl::vec2i position, Window ignore_window);