binds: add drag_threshold for click/drag isolation (#9839)

---------

Co-authored-by: Leeman <lstrout@enlj.com>
This commit is contained in:
alaricljs 2025-04-12 10:43:13 -04:00 committed by GitHub
parent 0399e64274
commit 6538970087
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 103 additions and 41 deletions

View file

@ -204,6 +204,13 @@ class IHyprLayout {
virtual Vector2D predictSizeForNewWindow(PHLWINDOW pWindow);
virtual Vector2D predictSizeForNewWindowFloating(PHLWINDOW pWindow);
/*
Called to try to pick up window for dragging.
Updates drag related variables and floats window if threshold reached.
Return true to reject
*/
virtual bool updateDragWindow();
private:
int m_iMouseMoveEventCount;
Vector2D m_vBeginDragXY;