This commit is contained in:
2025-12-07 01:35:33 +03:00
commit 6cc0a613dc
342 changed files with 166529 additions and 0 deletions

View File

@@ -0,0 +1,35 @@
#ifndef CLRSYNC_CORE_THEME_TEMPLATE_MANAGER_HPP
#define CLRSYNC_CORE_THEME_TEMPLATE_MANAGER_HPP
#include <core/config/config.hpp>
#include <core/theme/theme_template.hpp>
#include <string>
#include <unordered_map>
namespace clrsync::core
{
template <typename FileType>
class template_manager
{
public:
template_manager() = default;
std::unordered_map<std::string, theme_template> &templates()
{
auto themes = config::instance().templates();
m_templates.clear();
for (const auto &t : themes)
{
m_templates.insert({t.first, t.second});
}
return m_templates;
}
private:
std::unordered_map<std::string, theme_template> m_templates{};
};
} // namespace clrsync::core
#endif