From d98f7ffaf5ce8fcfe901e4cdcb3dc0d1a5f48816 Mon Sep 17 00:00:00 2001 From: Vaxry <43317083+vaxerski@users.noreply.github.com> Date: Mon, 2 Mar 2026 18:57:09 +0000 Subject: layout: store and preserve size and pos after fullscreen (#13500) ref https://github.com/hyprwm/Hyprland/discussions/13401 --- .../floating/default/DefaultFloatingAlgorithm.hpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp') diff --git a/src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp b/src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp index ef94e371..1e87fac1 100644 --- a/src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp +++ b/src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp @@ -1,5 +1,7 @@ #include "../../FloatingAlgorithm.hpp" +#include + namespace Layout { class CAlgorithm; } @@ -17,10 +19,22 @@ namespace Layout::Floating { virtual void resizeTarget(const Vector2D& Δ, SP target, eRectCorner corner = CORNER_NONE); virtual void moveTarget(const Vector2D& Δ, SP target); + virtual void setTargetGeom(const CBox& geom, SP target); + virtual void swapTargets(SP a, SP b); virtual void moveTargetInDirection(SP t, Math::eDirection dir, bool silent); + virtual void recenter(SP t); + private: CBox fitBoxInWorkArea(const CBox& box, SP t); + + void updateTarget(SP); + + struct SWindowData { + CBox lastBox; + }; + + std::map, SWindowData> m_datas; }; }; \ No newline at end of file -- cgit v1.2.3