Add tool configuration management and enhance UI functionality
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.
This commit is contained in:
13
inc/toolConfig.h
Normal file
13
inc/toolConfig.h
Normal file
@@ -0,0 +1,13 @@
|
||||
#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;
|
||||
};
|
||||
Reference in New Issue
Block a user