summaryrefslogtreecommitdiff
path: root/core/src/Model/GlobalStates.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/Model/GlobalStates.hpp')
-rw-r--r--core/src/Model/GlobalStates.hpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/core/src/Model/GlobalStates.hpp b/core/src/Model/GlobalStates.hpp
index e6d823b..8375569 100644
--- a/core/src/Model/GlobalStates.hpp
+++ b/core/src/Model/GlobalStates.hpp
@@ -10,6 +10,7 @@
class GlobalStates {
public:
static void Init();
+ static void Init(std::filesystem::path userDataDir);
static void Shutdown();
static GlobalStates& GetInstance();
@@ -31,6 +32,10 @@ public:
const std::vector<RecentProject>& GetRecentProjects() const;
void ClearRecentProjects();
void AddRecentProject(const Project& project);
+ /// Move or add the project to end of the recent projects list.
+ /// If the project is not in the list of recently used projects, it will be appended, otherwise
+ /// it will be moved to the end.
+ void MoveProjectToTop(const Project& project);
void RemoveRecentProject(int idx);
// TODO async autosaving to prevent data loss on crash