From e5a4c0c986f72813e8822f31ed3d5fa6be1b6c13 Mon Sep 17 00:00:00 2001 From: Vaxry <43317083+vaxerski@users.noreply.github.com> Date: Sun, 19 Feb 2023 21:07:32 +0000 Subject: Group/Tab Rework (#1580) --- src/Window.hpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/Window.hpp') diff --git a/src/Window.hpp b/src/Window.hpp index 658bdceb..65ac78f5 100644 --- a/src/Window.hpp +++ b/src/Window.hpp @@ -273,6 +273,12 @@ class CWindow { // for idle inhibiting windows eIdleInhibitMode m_eIdleInhibitMode = IDLEINHIBIT_NONE; + // for groups + struct SGroupData { + CWindow* pNextWindow = nullptr; // nullptr means no grouping. Self means single group. + bool head = false; + } m_sGroupData; + // For the list lookup bool operator==(const CWindow& rhs) { return m_uSurface.xdg == rhs.m_uSurface.xdg && m_uSurface.xwayland == rhs.m_uSurface.xwayland && m_vPosition == rhs.m_vPosition && m_vSize == rhs.m_vSize && @@ -303,6 +309,12 @@ class CWindow { bool isInCurvedCorner(double x, double y); bool hasPopupAt(const Vector2D& pos); + CWindow* getGroupHead(); + CWindow* getGroupTail(); + CWindow* getGroupCurrent(); + void setGroupCurrent(CWindow* pWindow); + void insertWindowToGroup(CWindow* pWindow); + private: // For hidden windows and stuff bool m_bHidden = false; -- cgit v1.2.3