From 5e6cec962c780956177e56355ffc1d64cc5f83ca Mon Sep 17 00:00:00 2001 From: Vaxry <43317083+vaxerski@users.noreply.github.com> Date: Fri, 31 Oct 2025 00:14:08 +0000 Subject: cursor: refactor override handling (#12166) much cleaner and more reliable. Should fix https://github.com/hyprwm/Hyprland/issues/12088 --- src/managers/input/InputManager.hpp | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'src/managers/input/InputManager.hpp') diff --git a/src/managers/input/InputManager.hpp b/src/managers/input/InputManager.hpp index 60ff49ef..9fbf68b4 100644 --- a/src/managers/input/InputManager.hpp +++ b/src/managers/input/InputManager.hpp @@ -193,11 +193,7 @@ class CInputManager { uint32_t getModsFromAllKBs(); // for virtual keyboards: whether we should respect them as normal ones - bool shouldIgnoreVirtualKeyboard(SP); - - // for special cursors that we choose - void setCursorImageUntilUnset(std::string); - void unsetCursorImage(); + bool shouldIgnoreVirtualKeyboard(SP); std::string getNameForNewDevice(std::string); @@ -226,6 +222,7 @@ class CInputManager { CHyprSignalListener newVirtualKeyboard; CHyprSignalListener newVirtualMouse; CHyprSignalListener setCursor; + CHyprSignalListener overrideChanged; } m_listeners; bool m_cursorImageOverridden = false; @@ -282,16 +279,12 @@ class CInputManager { void setBorderCursorIcon(eBorderIconDirection); void setCursorIconOnBorder(PHLWINDOW w); - // temporary. Obeys setUntilUnset. - void setCursorImageOverride(const std::string& name); - // cursor surface struct { bool hidden = false; // null surface = hidden SP wlSurface; Vector2D vHotspot; std::string name; // if not empty, means set by name. - bool inUse = false; } m_cursorSurfaceInfo; void restoreCursorIconToApp(); // no-op if restored -- cgit v1.2.3