Better detect focused x11 window on wayland, properly get focused game name on wayland

This commit is contained in:
dec05eba
2025-02-10 19:31:27 +01:00
parent f4e44cbef5
commit fc2f6f4c50
4 changed files with 24 additions and 8 deletions

View File

@@ -1452,6 +1452,8 @@ namespace gsr {
const Window gsr_ui_window = window ? window->get_system_handle() : None;
std::string focused_window_name = get_window_name_at_cursor_position(display, gsr_ui_window);
if(focused_window_name.empty())
focused_window_name = get_focused_window_name(display, WindowCaptureType::FOCUSED);
if(focused_window_name.empty())
focused_window_name = "Game";