mirror of
https://github.com/CalcProgrammer1/OpenRGB.git
synced 2026-01-21 21:47:54 -05:00
Rework Profiles to use JSON format
* Update OpenRGB Plugin Interface to include functions for loading/saving profile JSON data into OpenRGB profiles
* Update ProfileManager to handle auto-load profiles (Exit, Open, Resume, Suspend) and move their settings to ProfileManager section
* Update ProfileManager to store profiles in "profiles" folder in .json format
* Update ProfileManager to store size profile in sizes.json
* Update ProfileManager to perform device UpdateMode/UpdateColors when loading profile
* Code cleanup of ProfileManager and profile-related code
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
#include <QtPlugin>
|
||||
#include <QLabel>
|
||||
#include <QMenu>
|
||||
#include "nlohmann/json.hpp"
|
||||
#include "ResourceManagerInterface.h"
|
||||
|
||||
#define OpenRGBPluginInterface_IID "com.OpenRGBPluginInterface"
|
||||
@@ -87,6 +88,9 @@ public:
|
||||
virtual QWidget* GetWidget() = 0;
|
||||
virtual QMenu* GetTrayMenu() = 0;
|
||||
virtual void Unload() = 0;
|
||||
virtual void OnProfileAboutToLoad() = 0;
|
||||
virtual void OnProfileLoad(nlohmann::json profile_data) = 0;
|
||||
virtual nlohmann::json OnProfileSave() = 0;
|
||||
virtual unsigned char* OnSDKCommand(unsigned int pkt_id, unsigned char * pkt_data, unsigned int *pkt_size) = 0;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user