diff options
author | Daniel Lange <DLange@git.local> | 2024-01-10 11:17:08 +0100 |
---|---|---|
committer | Daniel Lange <DLange@git.local> | 2024-01-10 11:17:08 +0100 |
commit | e7372d18a1a661d8c3dba9f51e1f17b5f94171a7 (patch) | |
tree | e8270dd60ec096bee8157dbadf029e15ed584592 /Action.h | |
parent | 937052b231259a47d881d539ad5748245ef55b99 (diff) | |
download | debian_htop-e7372d18a1a661d8c3dba9f51e1f17b5f94171a7.tar.gz debian_htop-e7372d18a1a661d8c3dba9f51e1f17b5f94171a7.tar.bz2 debian_htop-e7372d18a1a661d8c3dba9f51e1f17b5f94171a7.zip |
New upstream version 3.3.0
Diffstat (limited to 'Action.h')
-rw-r--r-- | Action.h | 21 |
1 files changed, 9 insertions, 12 deletions
@@ -7,18 +7,15 @@ Released under the GNU GPLv2+, see the COPYING file in the source distribution for its full text. */ -#include "config.h" // IWYU pragma: keep - #include <stdbool.h> #include <sys/types.h> #include "Header.h" +#include "Machine.h" #include "Object.h" #include "Panel.h" #include "Process.h" -#include "ProcessList.h" #include "Settings.h" -#include "UsersTable.h" typedef enum { @@ -36,28 +33,28 @@ typedef enum { struct MainPanel_; // IWYU pragma: keep typedef struct State_ { - Settings* settings; - UsersTable* ut; - ProcessList* pl; + Machine* host; struct MainPanel_* mainPanel; Header* header; - bool pauseProcessUpdate; - bool hideProcessSelection; + bool pauseUpdate; + bool hideSelection; + bool hideMeters; } State; static inline bool State_hideFunctionBar(const State* st) { - return st->settings->hideFunctionBar == 2 || (st->settings->hideFunctionBar == 1 && st->hideProcessSelection); + const Settings* settings = st->host->settings; + return settings->hideFunctionBar == 2 || (settings->hideFunctionBar == 1 && st->hideSelection); } typedef Htop_Reaction (*Htop_Action)(State* st); -Object* Action_pickFromVector(State* st, Panel* list, int x, bool followProcess); +Object* Action_pickFromVector(State* st, Panel* list, int x, bool follow); bool Action_setUserOnly(const char* userName, uid_t* userId); Htop_Reaction Action_setSortKey(Settings* settings, ProcessField sortKey); -Htop_Reaction Action_setScreenTab(Settings* settings, int x); +Htop_Reaction Action_setScreenTab(State* st, int x); Htop_Reaction Action_follow(State* st); |