From ed411f53bdcf8d455f9e6ca769693aa84dc8372f Mon Sep 17 00:00:00 2001 From: Vaxry Date: Sun, 5 May 2024 22:18:10 +0100 Subject: cursor: move to a hyprland impl This moves wlr_cursor to a completely new impl mostly under CPointerManager Also adds beginSimple to OpenGL for simple render passes (e.g. cursor) --- src/managers/input/InputManager.hpp | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'src/managers/input/InputManager.hpp') diff --git a/src/managers/input/InputManager.hpp b/src/managers/input/InputManager.hpp index 7d78c133..a2caed46 100644 --- a/src/managers/input/InputManager.hpp +++ b/src/managers/input/InputManager.hpp @@ -7,15 +7,15 @@ #include "../../helpers/Timer.hpp" #include "InputMethodRelay.hpp" #include "../../helpers/signal/Listener.hpp" +#include "../../devices/IPointer.hpp" +#include "../../devices/ITouch.hpp" class CPointerConstraint; class CWindow; class CIdleInhibitor; class CVirtualKeyboardV1Resource; class CVirtualPointerV1Resource; -class IPointer; class IKeyboard; -class ITouch; enum eClickBehaviorMode { CLICKMODE_DEFAULT = 0, @@ -74,10 +74,10 @@ class CInputManager { CInputManager(); ~CInputManager(); - void onMouseMoved(wlr_pointer_motion_event*); - void onMouseWarp(wlr_pointer_motion_absolute_event*); - void onMouseButton(wlr_pointer_button_event*); - void onMouseWheel(wlr_pointer_axis_event*); + void onMouseMoved(IPointer::SMotionEvent); + void onMouseWarp(IPointer::SMotionAbsoluteEvent); + void onMouseButton(IPointer::SButtonEvent); + void onMouseWheel(IPointer::SAxisEvent); void onKeyboardKey(std::any, SP); void onKeyboardMod(SP); @@ -112,9 +112,9 @@ class CInputManager { eClickBehaviorMode getClickMode(); void processMouseRequest(wlr_seat_pointer_request_set_cursor_event* e); - void onTouchDown(wlr_touch_down_event*); - void onTouchUp(wlr_touch_up_event*); - void onTouchMove(wlr_touch_motion_event*); + void onTouchDown(ITouch::SDownEvent); + void onTouchUp(ITouch::SUpEvent); + void onTouchMove(ITouch::SMotionEvent); STouchData m_sTouchData; @@ -153,9 +153,9 @@ class CInputManager { void newIdleInhibitor(std::any); void recheckIdleInhibitorStatus(); - void onSwipeBegin(wlr_pointer_swipe_begin_event*); - void onSwipeEnd(wlr_pointer_swipe_end_event*); - void onSwipeUpdate(wlr_pointer_swipe_update_event*); + void onSwipeBegin(IPointer::SSwipeBeginEvent); + void onSwipeEnd(IPointer::SSwipeEndEvent); + void onSwipeUpdate(IPointer::SSwipeUpdateEvent); SSwipeGesture m_sActiveSwipe; @@ -212,8 +212,8 @@ class CInputManager { void setupKeyboard(SP keeb); void setupMouse(SP mauz); - void processMouseDownNormal(wlr_pointer_button_event* e); - void processMouseDownKill(wlr_pointer_button_event* e); + void processMouseDownNormal(const IPointer::SButtonEvent& e); + void processMouseDownKill(const IPointer::SButtonEvent& e); bool cursorImageUnlocked(); -- cgit v1.2.3