diff options
| author | Vaxry <43317083+vaxerski@users.noreply.github.com> | 2024-04-27 12:43:12 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-27 12:43:12 +0100 |
| commit | bca7804bb6e1bf5ce5a99b9ae4806be25e36993c (patch) | |
| tree | ebd3a578de1dfe11b54f9440cfc3a408ffa6a620 /src/managers/input/InputManager.hpp | |
| parent | 25aec3ac8ce65ed224f025f8f6dfef73780577a4 (diff) | |
internal: Window storage rework - part 1 (#5762)
* Window storage rework - part 1
* format
* remove useless include
* fix pch
* format
* fix crash in dwindle
* fix vram leak
* prefer .expired() for bool checks
Diffstat (limited to 'src/managers/input/InputManager.hpp')
| -rw-r--r-- | src/managers/input/InputManager.hpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/managers/input/InputManager.hpp b/src/managers/input/InputManager.hpp index 2795d410..e20bca2a 100644 --- a/src/managers/input/InputManager.hpp +++ b/src/managers/input/InputManager.hpp @@ -38,7 +38,7 @@ enum eBorderIconDirection { }; struct STouchData { - CWindow* touchFocusWindow = nullptr; + PHLWINDOWREF touchFocusWindow; SLayerSurface* touchFocusLS = nullptr; wlr_surface* touchFocusSurface = nullptr; Vector2D touchSurfaceOrigin; @@ -114,12 +114,12 @@ class CInputManager { STouchData m_sTouchData; // for dragging floating windows - CWindow* currentlyDraggedWindow = nullptr; - eMouseBindMode dragMode = MBIND_INVALID; - bool m_bWasDraggingWindow = false; + PHLWINDOWREF currentlyDraggedWindow; + eMouseBindMode dragMode = MBIND_INVALID; + bool m_bWasDraggingWindow = false; // for refocus to be forced - CWindow* m_pForcedFocus = nullptr; + PHLWINDOWREF m_pForcedFocus; SDrag m_sDrag; @@ -188,7 +188,7 @@ class CInputManager { bool m_bLastInputTouch = false; // for tracking mouse refocus - CWindow* m_pLastMouseFocus = nullptr; + PHLWINDOWREF m_pLastMouseFocus; wlr_surface* m_pLastMouseSurface = nullptr; // @@ -226,7 +226,7 @@ class CInputManager { // this will be set after a refocus() wlr_surface* m_pFoundSurfaceToFocus = nullptr; SLayerSurface* m_pFoundLSToFocus = nullptr; - CWindow* m_pFoundWindowToFocus = nullptr; + PHLWINDOWREF m_pFoundWindowToFocus; // for holding focus on buttons held bool m_bFocusHeldByButtons = false; @@ -238,7 +238,7 @@ class CInputManager { // idle inhibitors struct SIdleInhibitor { std::shared_ptr<CIdleInhibitor> inhibitor; - CWindow* pWindow = nullptr; + PHLWINDOWREF pWindow; CHyprSignalListener windowDestroyListener; }; std::vector<std::unique_ptr<SIdleInhibitor>> m_vIdleInhibitors; @@ -249,7 +249,7 @@ class CInputManager { void endWorkspaceSwipe(); void setBorderCursorIcon(eBorderIconDirection); - void setCursorIconOnBorder(CWindow* w); + void setCursorIconOnBorder(PHLWINDOW w); // temporary. Obeys setUntilUnset. void setCursorImageOverride(const std::string& name); |
