mirror of
https://github.com/xzeldon/htop.git
synced 2025-07-12 12:14:36 +03:00
Highlight new and old processes (#74)
This commit is contained in:
11
Process.h
11
Process.h
@ -10,17 +10,18 @@ in the source distribution for its full text.
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <sys/types.h>
|
||||
#include <time.h>
|
||||
|
||||
#include "Object.h"
|
||||
#include "RichString.h"
|
||||
|
||||
|
||||
#ifdef __ANDROID__
|
||||
#define SYS_ioprio_get __NR_ioprio_get
|
||||
#define SYS_ioprio_set __NR_ioprio_set
|
||||
#endif
|
||||
|
||||
#define PROCESS_FLAG_IO 0x0001
|
||||
#define DEFAULT_HIGHLIGHT_SECS 5
|
||||
|
||||
typedef enum ProcessFields {
|
||||
NULL_PROCESSFIELD = 0,
|
||||
@ -59,6 +60,7 @@ struct Settings_;
|
||||
typedef struct Process_ {
|
||||
Object super;
|
||||
|
||||
const struct ProcessList_* processList;
|
||||
const struct Settings_* settings;
|
||||
|
||||
unsigned long long int time;
|
||||
@ -99,6 +101,9 @@ typedef struct Process_ {
|
||||
|
||||
int exit_signal;
|
||||
|
||||
time_t seenTs;
|
||||
time_t tombTs;
|
||||
|
||||
unsigned long int minflt;
|
||||
unsigned long int majflt;
|
||||
} Process;
|
||||
@ -172,6 +177,10 @@ void Process_init(Process* this, const struct Settings_* settings);
|
||||
|
||||
void Process_toggleTag(Process* this);
|
||||
|
||||
bool Process_isNew(const Process* this);
|
||||
|
||||
bool Process_isTomb(const Process* this);
|
||||
|
||||
bool Process_setPriority(Process* this, int priority);
|
||||
|
||||
bool Process_changePriorityBy(Process* this, Arg delta);
|
||||
|
Reference in New Issue
Block a user