summaryrefslogtreecommitdiffstats
path: root/Settings.h
diff options
context:
space:
mode:
authorNathan Scott <nathans@redhat.com>2023-04-04 16:24:37 +1000
committerBenBE <BenBE@geshi.org>2023-04-06 00:19:54 +0200
commite7f447b6a3473a572d3e6c191128f1796477860d (patch)
tree1e8a90d216055dfe77b688fc48c0a42f18637d71 /Settings.h
parentc8a61850dd31ab64eb8ad83929ce86d2adbeb96c (diff)
Refactor and consolidate dynamic meters/columns pointers
This removes the duplication of dynamic meter/column hashtable pointers that has come in between the Settings and ProcessList structures - only one copy of these is needed. With the future planned dynamic screens feature adding another pointer, let us first clean this up before any further duplication happens.
Diffstat (limited to 'Settings.h')
-rw-r--r--Settings.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/Settings.h b/Settings.h
index baf05da3..48c62590 100644
--- a/Settings.h
+++ b/Settings.h
@@ -51,7 +51,8 @@ typedef struct Settings_ {
int config_version;
HeaderLayout hLayout;
MeterColumnSetting* hColumns;
- Hashtable* dynamicColumns;
+ Hashtable* dynamicColumns; /* runtime-discovered columns */
+ Hashtable* dynamicMeters; /* runtime-discovered meters */
ScreenSettings** screens;
unsigned int nScreens;
@@ -117,7 +118,7 @@ void Settings_delete(Settings* this);
int Settings_write(const Settings* this, bool onCrash);
-Settings* Settings_new(unsigned int initialCpuCount, Hashtable* dynamicColumns);
+Settings* Settings_new(unsigned int initialCpuCount, Hashtable* dynamicMeters, Hashtable* dynamicColumns);
ScreenSettings* Settings_newScreen(Settings* this, const ScreenDefaults* defaults);

© 2014-2024 Faster IT GmbH | imprint | privacy policy