diff options
| author | Vaxry <43317083+vaxerski@users.noreply.github.com> | 2026-04-28 15:56:07 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-04-28 15:56:07 +0100 |
| commit | 98fbbafef78057c818fb02b15c27e38ad2f5b5bc (patch) | |
| tree | c62aa1eae704e7595d58f7edeb3804e8bfd0099d /src/layout/LayoutManager.hpp | |
| parent | d4c6ff434c5c7aa66bc7c28e5ce336d2a694bfcc (diff) | |
config/errors: Report and categorize errors properly for actions (#14192)
Makes all errors categorized, some not displayed, some displayed.
All errors can be obtained after hl.dispatch()
Diffstat (limited to 'src/layout/LayoutManager.hpp')
| -rw-r--r-- | src/layout/LayoutManager.hpp | 43 |
1 files changed, 22 insertions, 21 deletions
diff --git a/src/layout/LayoutManager.hpp b/src/layout/LayoutManager.hpp index e99911d5..2660cf28 100644 --- a/src/layout/LayoutManager.hpp +++ b/src/layout/LayoutManager.hpp @@ -3,6 +3,7 @@ #include "../helpers/memory/Memory.hpp" #include "../helpers/math/Math.hpp" #include "../managers/input/InputManager.hpp" +#include "../config/shared/ConfigErrors.hpp" #include "supplementary/DragController.hpp" @@ -44,38 +45,38 @@ namespace Layout { CLayoutManager(); ~CLayoutManager() = default; - void newTarget(SP<ITarget> target, SP<CSpace> space); - void removeTarget(SP<ITarget> target); + void newTarget(SP<ITarget> target, SP<CSpace> space); + void removeTarget(SP<ITarget> target); - void changeFloatingMode(SP<ITarget> target); + void changeFloatingMode(SP<ITarget> target); - void beginDragTarget(SP<ITarget> target, eMouseBindMode mode); - void moveMouse(const Vector2D& mousePos); - void resizeTarget(const Vector2D& Δ, SP<ITarget> target, eRectCorner corner = CORNER_NONE); - void moveTarget(const Vector2D& Δ, SP<ITarget> target); - void setTargetGeom(const CBox& box, SP<ITarget> target); // floats only - void endDragTarget(); + void beginDragTarget(SP<ITarget> target, eMouseBindMode mode); + void moveMouse(const Vector2D& mousePos); + void resizeTarget(const Vector2D& Δ, SP<ITarget> target, eRectCorner corner = CORNER_NONE); + void moveTarget(const Vector2D& Δ, SP<ITarget> target); + void setTargetGeom(const CBox& box, SP<ITarget> target); // floats only + void endDragTarget(); - std::expected<void, std::string> layoutMsg(const std::string_view& sv); + Config::ErrorResult layoutMsg(const std::string_view& sv); - void fullscreenRequestForTarget(SP<ITarget> target, eFullscreenMode currentEffectiveMode, eFullscreenMode effectiveMode); + void fullscreenRequestForTarget(SP<ITarget> target, eFullscreenMode currentEffectiveMode, eFullscreenMode effectiveMode); - void switchTargets(SP<ITarget> a, SP<ITarget> b, bool preserveFocus = true); + void switchTargets(SP<ITarget> a, SP<ITarget> b, bool preserveFocus = true); - void moveInDirection(SP<ITarget> target, const std::string& direction, bool silent = false); + void moveInDirection(SP<ITarget> target, const std::string& direction, bool silent = false); - SP<ITarget> getNextCandidate(SP<CSpace> space, SP<ITarget> from); + SP<ITarget> getNextCandidate(SP<CSpace> space, SP<ITarget> from); - bool isReachable(SP<ITarget> target); + bool isReachable(SP<ITarget> target); - void bringTargetToTop(SP<ITarget> target); + void bringTargetToTop(SP<ITarget> target); - std::optional<Vector2D> predictSizeForNewTiledTarget(); + std::optional<Vector2D> predictSizeForNewTiledTarget(); - void performSnap(Vector2D& sourcePos, Vector2D& sourceSize, SP<ITarget> target, eMouseBindMode mode, int corner, const Vector2D& beginSize); + void performSnap(Vector2D& sourcePos, Vector2D& sourceSize, SP<ITarget> target, eMouseBindMode mode, int corner, const Vector2D& beginSize); - void invalidateMonitorGeometries(PHLMONITOR); - void recalculateMonitor(PHLMONITOR); + void invalidateMonitorGeometries(PHLMONITOR); + void recalculateMonitor(PHLMONITOR); const UP<Supplementary::CDragStateController>& dragController(); @@ -84,4 +85,4 @@ namespace Layout { }; } -inline UP<Layout::CLayoutManager> g_layoutManager;
\ No newline at end of file +inline UP<Layout::CLayoutManager> g_layoutManager; |
