2023-12-11 15:54:22 +01:00
|
|
|
#include <hex/api/content_registry.hpp>
|
2023-12-12 00:16:21 +01:00
|
|
|
#include <hex/api/task_manager.hpp>
|
2023-12-11 15:54:22 +01:00
|
|
|
#include <hex/api/workspace_manager.hpp>
|
|
|
|
|
|
|
|
#include <hex/helpers/fs.hpp>
|
|
|
|
|
|
|
|
namespace hex::plugin::builtin {
|
|
|
|
|
|
|
|
void loadWorkspaces() {
|
2024-02-28 22:10:48 +01:00
|
|
|
WorkspaceManager::reload();
|
2023-12-12 00:16:21 +01:00
|
|
|
|
2024-02-28 22:10:48 +01:00
|
|
|
auto currentWorkspace = ContentRegistry::Settings::read<std::string>("hex.builtin.setting.general", "hex.builtin.setting.general.curr_workspace", "Default");
|
2023-12-12 00:16:21 +01:00
|
|
|
TaskManager::doLater([currentWorkspace] {
|
|
|
|
WorkspaceManager::switchWorkspace(currentWorkspace);
|
|
|
|
});
|
2023-12-11 15:54:22 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|