summaryrefslogtreecommitdiff
path: root/src/Compositor.hpp
diff options
context:
space:
mode:
authordavc0n <dconti.dev@gmail.com>2025-04-22 15:23:29 +0200
committerGitHub <noreply@github.com>2025-04-22 15:23:29 +0200
commit241a4935a244f403fa7108259075b04c81ed258f (patch)
tree50cc20b69c522c2be5396417931f799cac87138d /src/Compositor.hpp
parent3577a6be31fa26539b4088ea07aa2221f84b132e (diff)
compositor: refactor class member vars (#10141)
Diffstat (limited to 'src/Compositor.hpp')
-rw-r--r--src/Compositor.hpp79
1 files changed, 39 insertions, 40 deletions
diff --git a/src/Compositor.hpp b/src/Compositor.hpp
index 33780cc9..32e65286 100644
--- a/src/Compositor.hpp
+++ b/src/Compositor.hpp
@@ -25,29 +25,29 @@ class CCompositor {
CCompositor(bool onlyConfig = false);
~CCompositor();
- wl_display* m_sWLDisplay = nullptr;
- wl_event_loop* m_sWLEventLoop = nullptr;
- int m_iDRMFD = -1;
- bool m_bInitialized = false;
- SP<Aquamarine::CBackend> m_pAqBackend;
-
- std::string m_szHyprTempDataRoot = "";
-
- std::string m_szWLDisplaySocket = "";
- std::string m_szInstanceSignature = "";
- std::string m_szInstancePath = "";
- std::string m_szCurrentSplash = "error";
-
- std::vector<PHLMONITOR> m_vMonitors;
- std::vector<PHLMONITOR> m_vRealMonitors; // for all monitors, even those turned off
- std::vector<PHLWINDOW> m_vWindows;
- std::vector<PHLLS> m_vLayers;
- std::vector<PHLWORKSPACE> m_vWorkspaces;
- std::vector<PHLWINDOWREF> m_vWindowsFadingOut;
- std::vector<PHLLSREF> m_vSurfacesFadingOut;
-
- std::unordered_map<std::string, MONITORID> m_mMonitorIDMap;
- std::unordered_map<std::string, WORKSPACEID> m_mSeenMonitorWorkspaceMap; // map of seen monitor names to workspace IDs
+ wl_display* m_wlDisplay = nullptr;
+ wl_event_loop* m_wlEventLoop = nullptr;
+ int m_drmFD = -1;
+ bool m_initialized = false;
+ SP<Aquamarine::CBackend> m_aqBackend;
+
+ std::string m_hyprTempDataRoot = "";
+
+ std::string m_wlDisplaySocket = "";
+ std::string m_instanceSignature = "";
+ std::string m_instancePath = "";
+ std::string m_currentSplash = "error";
+
+ std::vector<PHLMONITOR> m_monitors;
+ std::vector<PHLMONITOR> m_realMonitors; // for all monitors, even those turned off
+ std::vector<PHLWINDOW> m_windows;
+ std::vector<PHLLS> m_layers;
+ std::vector<PHLWORKSPACE> m_workspaces;
+ std::vector<PHLWINDOWREF> m_windowsFadingOut;
+ std::vector<PHLLSREF> m_surfacesFadingOut;
+
+ std::unordered_map<std::string, MONITORID> m_monitorIDMap;
+ std::unordered_map<std::string, WORKSPACEID> m_seenMonitorWorkspaceMap; // map of seen monitor names to workspace IDs
void initServer(std::string socketName, int socketFd);
void startCompositor();
@@ -56,23 +56,22 @@ class CCompositor {
void bumpNofile();
void restoreNofile();
- WP<CWLSurfaceResource> m_pLastFocus;
- PHLWINDOWREF m_pLastWindow;
- PHLMONITORREF m_pLastMonitor;
-
- std::vector<PHLWINDOWREF> m_vWindowFocusHistory; // first element is the most recently focused.
-
- bool m_bReadyToProcess = false;
- bool m_bSessionActive = true;
- bool m_bDPMSStateON = true;
- bool m_bUnsafeState = false; // unsafe state is when there is no monitors.
- bool m_bNextIsUnsafe = false;
- PHLMONITORREF m_pUnsafeOutput; // fallback output for the unsafe state
- bool m_bIsShuttingDown = false;
- bool m_bFinalRequests = false;
- bool m_bDesktopEnvSet = false;
- bool m_bWantsXwayland = true;
- bool m_bOnlyConfigVerification = false;
+ WP<CWLSurfaceResource> m_lastFocus;
+ PHLWINDOWREF m_lastWindow;
+ PHLMONITORREF m_lastMonitor;
+
+ std::vector<PHLWINDOWREF> m_windowFocusHistory; // first element is the most recently focused
+
+ bool m_readyToProcess = false;
+ bool m_sessionActive = true;
+ bool m_dpmsStateOn = true;
+ bool m_unsafeState = false; // unsafe state is when there is no monitors
+ PHLMONITORREF m_unsafeOutput; // fallback output for the unsafe state
+ bool m_isShuttingDown = false;
+ bool m_finalRequests = false;
+ bool m_desktopEnvSet = false;
+ bool m_wantsXwayland = true;
+ bool m_onlyConfigVerification = false;
// ------------------------------------------------- //