Introduce `ToolConfigStore` for managing tool configuration files, enabling retrieval and updates. Refactor window handling to support Lua timeout settings and dynamic tool-specific configurations. Improve HTML UI with Lua timeout adjustments and centralized styling updates.
14 lines
496 B
C++
14 lines
496 B
C++
#pragma once
|
|
|
|
#include <filesystem>
|
|
#include <string>
|
|
|
|
class ToolConfigStore {
|
|
public:
|
|
bool ensureExists(const std::filesystem::path &path) const;
|
|
int getInt(const std::filesystem::path &path, const std::string &key, int fallback) const;
|
|
void setInt(const std::filesystem::path &path, const std::string &key, int value) const;
|
|
std::string readAll(const std::filesystem::path &path) const;
|
|
void writeAll(const std::filesystem::path &path, const std::string &content) const;
|
|
};
|