summaryrefslogtreecommitdiffstats
path: root/ScreenManager.c
diff options
context:
space:
mode:
authorNathan Scott <nathans@redhat.com>2023-05-02 16:56:18 +1000
committerNathan Scott <nathans@redhat.com>2023-05-08 13:06:38 +1000
commit72235d8e098d9d79029dca65122605741e1aafad (patch)
tree96593b8bd9dc95dc5ab321bd363d36351cbd0a99 /ScreenManager.c
parent0bdade1b6cb40c5bd374a93ac0489058a7421bb5 (diff)
Adapt platform code for the new Machine base class
Move host-centric data to new derived <Platform>Machine classes, separate from process-list-centric data.
Diffstat (limited to 'ScreenManager.c')
-rw-r--r--ScreenManager.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/ScreenManager.c b/ScreenManager.c
index f1897893..18e09343 100644
--- a/ScreenManager.c
+++ b/ScreenManager.c
@@ -16,6 +16,7 @@ in the source distribution for its full text.
#include "CRT.h"
#include "FunctionBar.h"
+#include "Machine.h"
#include "Macros.h"
#include "Object.h"
#include "Platform.h"
@@ -135,8 +136,10 @@ static void checkRecalculation(ScreenManager* this, double* oldTime, int* sortTi
host->pl->needsSort = true;
*sortTimeout = 1;
}
- // scan processes first - some header values are calculated there
- ProcessList_scan(host->pl, this->state->pauseUpdate);
+ // sample current values for system metrics and processes if not paused
+ Machine_scan(host);
+ if (!this->state->pauseUpdate)
+ ProcessList_scan(host->pl);
// always update header, especially to avoid gaps in graph meters
Header_updateData(this->header);
// force redraw if the number of UID digits was changed

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