first commit

This commit is contained in:
2026-01-02 19:20:35 +09:00
commit a10cb30c4a
94 changed files with 28609 additions and 0 deletions

37
utils/configmanager.h Normal file
View File

@@ -0,0 +1,37 @@
#ifndef CONFIGMANAGER_H
#define CONFIGMANAGER_H
#include <QObject>
#include <QJsonDocument>
#include <QJsonObject>
#include <QJsonArray>
#include <QVector>
#include "../widgets/appicon.h"
#include "../widgets/launcherpage.h"
class ConfigManager : public QObject
{
Q_OBJECT
public:
explicit ConfigManager(QObject *parent = nullptr);
~ConfigManager();
bool loadFromFile(const QString &filePath);
bool loadDefaultConfig();
bool saveToFile(const QString &filePath);
QVector<PageConfig> getPages() const;
QVector<AppIconData> getDockApps() const;
QJsonObject getColorSystem() const;
QJsonObject getAnimations() const;
private:
AppIconData parseAppData(const QJsonObject &obj) const;
PageConfig parsePageConfig(const QJsonObject &obj) const;
QJsonDocument m_configDoc;
QJsonObject m_config;
};
#endif // CONFIGMANAGER_H