1991afb87b
* sys: Initial refactoring of the SharedData class * sys/pattern: More refactoring, make every provider have its own patterns * sys: Finished up refactoring. No more SharedData! * sys: Fixed compile on Unix * tests: Fixed unit tests * sys: Moved view and lang files * pattern: Added assignment operator support to for loops * tests: Fixed compile issue
38 lines
702 B
C++
38 lines
702 B
C++
#pragma once
|
|
|
|
#include <hex/ui/view.hpp>
|
|
|
|
#include <cstdio>
|
|
#include <string>
|
|
|
|
namespace hex::plugin::builtin {
|
|
|
|
enum class ConstantType {
|
|
Int10,
|
|
Int16BigEndian,
|
|
Int16LittleEndian
|
|
};
|
|
|
|
struct Constant {
|
|
std::string name, description;
|
|
std::string category;
|
|
ConstantType type;
|
|
std::string value;
|
|
};
|
|
|
|
class ViewConstants : public View {
|
|
public:
|
|
explicit ViewConstants();
|
|
~ViewConstants() override;
|
|
|
|
void drawContent() override;
|
|
|
|
private:
|
|
void reloadConstants();
|
|
|
|
std::vector<Constant> m_constants;
|
|
std::vector<size_t> m_filterIndices;
|
|
std::string m_filter;
|
|
};
|
|
|
|
} |