diff options
author | Jakob P. Liljenberg <admin@qvantnet.com> | 2024-01-03 16:34:01 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-03 16:34:01 +0100 |
commit | ef788efc536733a441949dab854b0a6bea5ef33e (patch) | |
tree | 4a27a7212369425705973fc29f9c8feff00b00ba /src/btop_config.hpp | |
parent | c90e3f9b1508f55d281495468297df409f974eb0 (diff) | |
parent | a29545c4079e9bc5203e09965ac03fabe975bd7e (diff) |
Merge branch 'main' into lldb-term-size
Diffstat (limited to 'src/btop_config.hpp')
-rw-r--r-- | src/btop_config.hpp | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/src/btop_config.hpp b/src/btop_config.hpp index e5f4ac1..2b586af 100644 --- a/src/btop_config.hpp +++ b/src/btop_config.hpp @@ -22,11 +22,10 @@ tab-size = 4 #include <vector> #include <filesystem> -#include <robin_hood.h> +#include <unordered_map> using std::string; using std::vector; -using robin_hood::unordered_flat_map; //* Functions and variables for reading and writing the btop config file namespace Config { @@ -34,18 +33,25 @@ namespace Config { extern std::filesystem::path conf_dir; extern std::filesystem::path conf_file; - extern unordered_flat_map<std::string_view, string> strings; - extern unordered_flat_map<std::string_view, string> stringsTmp; - extern unordered_flat_map<std::string_view, bool> bools; - extern unordered_flat_map<std::string_view, bool> boolsTmp; - extern unordered_flat_map<std::string_view, int> ints; - extern unordered_flat_map<std::string_view, int> intsTmp; + extern std::unordered_map<std::string_view, string> strings; + extern std::unordered_map<std::string_view, string> stringsTmp; + extern std::unordered_map<std::string_view, bool> bools; + extern std::unordered_map<std::string_view, bool> boolsTmp; + extern std::unordered_map<std::string_view, int> ints; + extern std::unordered_map<std::string_view, int> intsTmp; const vector<string> valid_graph_symbols = { "braille", "block", "tty" }; const vector<string> valid_graph_symbols_def = { "default", "braille", "block", "tty" }; - const vector<string> valid_boxes = { "cpu", "mem", "net", "proc" }; + const vector<string> valid_boxes = { + "cpu", "mem", "net", "proc" +#ifdef GPU_SUPPORT + ,"gpu0", "gpu1", "gpu2", "gpu3", "gpu4", "gpu5" +#endif + }; const vector<string> temp_scales = { "celsius", "fahrenheit", "kelvin", "rankine" }; - +#ifdef GPU_SUPPORT + const vector<string> show_gpu_values = { "Auto", "On", "Off" }; +#endif extern vector<string> current_boxes; extern vector<string> preset_list; extern vector<string> available_batteries; |