summaryrefslogtreecommitdiff
path: root/src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp
diff options
context:
space:
mode:
authorVaxry <43317083+vaxerski@users.noreply.github.com>2026-03-02 18:57:09 +0000
committerGitHub <noreply@github.com>2026-03-02 18:57:09 +0000
commitd98f7ffaf5ce8fcfe901e4cdcb3dc0d1a5f48816 (patch)
treee4d35bfca286f36d56f859370aa0b5b2f8681c24 /src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp
parent5f650f8ed99705f51b473e592c974a7ddaa3c9d7 (diff)
layout: store and preserve size and pos after fullscreen (#13500)
ref https://github.com/hyprwm/Hyprland/discussions/13401
Diffstat (limited to 'src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp')
-rw-r--r--src/layout/algorithm/floating/default/DefaultFloatingAlgorithm.hpp14
1 files changed, 14 insertions, 0 deletions
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 <map>
+
namespace Layout {
class CAlgorithm;
}
@@ -17,10 +19,22 @@ namespace Layout::Floating {
virtual void resizeTarget(const Vector2D& Δ, SP<ITarget> target, eRectCorner corner = CORNER_NONE);
virtual void moveTarget(const Vector2D& Δ, SP<ITarget> target);
+ virtual void setTargetGeom(const CBox& geom, SP<ITarget> target);
+
virtual void swapTargets(SP<ITarget> a, SP<ITarget> b);
virtual void moveTargetInDirection(SP<ITarget> t, Math::eDirection dir, bool silent);
+ virtual void recenter(SP<ITarget> t);
+
private:
CBox fitBoxInWorkArea(const CBox& box, SP<ITarget> t);
+
+ void updateTarget(SP<ITarget>);
+
+ struct SWindowData {
+ CBox lastBox;
+ };
+
+ std::map<WP<ITarget>, SWindowData> m_datas;
};
}; \ No newline at end of file