mirror of
https://github.com/virtcode/hypr-dynamic-cursors
synced 2025-09-19 16:13:21 +02:00
fix: better error handling and event loop
This commit is contained in:
parent
17f8bc1c62
commit
91c03dea2e
6 changed files with 69 additions and 49 deletions
|
@ -4,6 +4,7 @@
|
|||
#include <hyprland/src/managers/PointerManager.hpp>
|
||||
#undef private
|
||||
#include <hyprutils/math/Vector2D.hpp>
|
||||
#include <hyprland/src/managers/eventLoop/EventLoopManager.hpp>
|
||||
|
||||
#include "mode/ModeRotate.hpp"
|
||||
#include "mode/ModeTilt.hpp"
|
||||
|
@ -11,6 +12,9 @@
|
|||
|
||||
class CDynamicCursors {
|
||||
public:
|
||||
CDynamicCursors();
|
||||
~CDynamicCursors();
|
||||
|
||||
/* hook on onCursorMoved */
|
||||
void onCursorMoved(CPointerManager* pointers);
|
||||
/* called on tick */
|
||||
|
@ -26,6 +30,8 @@ class CDynamicCursors {
|
|||
bool setHardware(CPointerManager* pointers, SP<CPointerManager::SMonitorPointerState> state, wlr_buffer* buf);
|
||||
|
||||
private:
|
||||
SP<CEventLoopTimer> tick;
|
||||
|
||||
// current angle of the cursor in radiants
|
||||
double angle;
|
||||
// current zoom value of the cursor
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue