Hyprland/src/managers/LayoutManager.hpp

32 lines
912 B
C++
Raw Normal View History

#pragma once
#include "../layout/DwindleLayout.hpp"
2022-07-16 15:57:31 +02:00
#include "../layout/MasterLayout.hpp"
class CLayoutManager {
public:
CLayoutManager();
IHyprLayout* getCurrentLayout();
void switchToLayout(std::string);
bool addLayout(const std::string& name, IHyprLayout* layout);
bool removeLayout(IHyprLayout* layout);
std::vector<std::string> getAllLayoutNames();
private:
enum HYPRLAYOUTS {
2022-12-26 12:05:34 +01:00
LAYOUT_DWINDLE = 0,
LAYOUT_MASTER
};
int m_iCurrentLayoutID = LAYOUT_DWINDLE;
CHyprDwindleLayout m_cDwindleLayout;
CHyprMasterLayout m_cMasterLayout;
std::vector<std::pair<std::string, IHyprLayout*>> m_vLayouts;
};
inline std::unique_ptr<CLayoutManager> g_pLayoutManager;