From 2c9d13e954c2ee66ff4d43949bedc73e60637a34 Mon Sep 17 00:00:00 2001 From: BossCode45 Date: Sun, 12 Nov 2023 15:50:47 +1300 Subject: refactor: Restructed the `Frame' class Now includes a pointer to a `RootData' class for root windows (workspaces) --- structs.h | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'structs.h') diff --git a/structs.h b/structs.h index 8215bf5..c2436f3 100644 --- a/structs.h +++ b/structs.h @@ -23,6 +23,13 @@ enum TileDir noDir }; +struct RootData +{ + std::vector floatingFrameIDs; + //int workspaceNumber; + //int whichChildFocused = 0; +}; + struct Frame { int ID; @@ -30,15 +37,15 @@ struct Frame bool isClient; - //If its a client (window) + // If its a client (window) int cID; - //If it isn't a client + // If it isn't a client TileDir dir; std::vector subFrameIDs; - bool isRoot; - std::vector floatingFrameIDs; - //int whichChildFocused = 0; + + // Null if not root + RootData* rootData; }; struct ScreenInfo -- cgit v1.2.3