feat: Allow custom hashes to be saved to projects

This commit is contained in:
WerWolv
2023-01-18 14:30:56 +01:00
parent c747c15567
commit ef12798fe2
5 changed files with 138 additions and 15 deletions

View File

@@ -1,6 +1,6 @@
#pragma once
#include <map>
#include <hex/api/content_registry.hpp>
#include <hex/providers/provider.hpp>
#include <pl/pattern_language.hpp>
@@ -8,6 +8,8 @@
#include <hex/data_processor/node.hpp>
#include <hex/data_processor/link.hpp>
#include <map>
namespace hex::plugin::builtin {
class ProviderExtraData {
@@ -73,6 +75,10 @@ namespace hex::plugin::builtin {
std::optional<u64> selectionStart, selectionEnd;
float scrollPosition = 0.0F;
} editor;
struct Hashes {
std::vector<ContentRegistry::Hashes::Hash::Function> hashFunctions;
} hashes;
};
static Data& getCurrent() {