aboutsummaryrefslogtreecommitdiff
path: root/core/src/UI/States.hpp
blob: 4cc3b0f6103eedbda8234ee948ae3d2311a085fe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#pragma once

#include "cplt_fwd.hpp"

#include <memory>
#include <imgui.h>

/// Minimal state shared by all UI components, such as database, items, export, etc.
/// Note that global components (settings) is not supposed to access these.
class UIState {
public:
	static void Init();
	static void Shutdown();
	static UIState& GetInstance();

public:
	std::unique_ptr<Project> CurrentProject;

public:
	void SetCurrentProject(std::unique_ptr<Project> project);
	void CloseCurrentProject();
};