Plugin System (#1590)

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
This commit is contained in:
Vaxry 2023-02-27 12:32:38 +00:00 committed by GitHub
parent 74a10f26a4
commit 8b81f41e52
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
45 changed files with 1691 additions and 85 deletions

View file

@ -5,20 +5,28 @@
class CLayoutManager {
public:
CLayoutManager();
IHyprLayout* getCurrentLayout();
void switchToLayout(std::string);
bool addLayout(const std::string& name, IHyprLayout* layout);
bool removeLayout(IHyprLayout* layout);
private:
enum HYPRLAYOUTS {
enum HYPRLAYOUTS
{
LAYOUT_DWINDLE = 0,
LAYOUT_MASTER
};
HYPRLAYOUTS m_iCurrentLayoutID = LAYOUT_DWINDLE;
int m_iCurrentLayoutID = LAYOUT_DWINDLE;
CHyprDwindleLayout m_cDwindleLayout;
CHyprMasterLayout m_cMasterLayout;
CHyprDwindleLayout m_cDwindleLayout;
CHyprMasterLayout m_cMasterLayout;
std::vector<std::pair<std::string, IHyprLayout*>> m_vLayouts;
};
inline std::unique_ptr<CLayoutManager> g_pLayoutManager;