Update memory sizes to 64 bit and fix compilation warnings.
[lxde/lxtask.git] / src / types.h
1 /* $Id: types.h 3940 2008-02-10 22:48:45Z nebulon $
2 *
3 * Copyright (c) 2006 Johannes Zellner, <webmaster@nebulon.de>
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU Library General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18 */
19
20 #ifndef TYPES_H
21 #define TYPES_H
22
23 #include <gtk/gtk.h>
24
25 #define REFRESH_INTERVAL 1000
26
27 struct task
28 {
29 pid_t pid;
30 pid_t ppid;
31 uid_t uid;
32 gchar uname[64];
33 gchar name[255];
34 gchar state[16];
35 guint64 size;
36 guint64 rss;
37 gboolean checked;
38 gint time;
39 gint old_time;
40 gfloat time_percentage;
41 gint prio; /* my change */
42 };
43
44 typedef struct
45 {
46 guint mem_total;
47 guint mem_free;
48 guint mem_cached;
49 guint mem_buffered;
50 guint cpu_count;
51 guint cpu_idle;
52 guint cpu_user;
53 guint cpu_nice;
54 guint cpu_system;
55 guint cpu_old_jiffies;
56 guint cpu_old_used;
57 gboolean valid_proc_reading;
58 } system_status;
59
60 extern GtkWidget *main_window;
61
62 extern GArray *task_array;
63 extern gint tasks;
64 extern uid_t own_uid;
65
66 extern gchar *config_file;
67
68 extern gboolean show_user_tasks;
69 extern gboolean show_root_tasks;
70 extern gboolean show_other_tasks;
71 extern gboolean show_full_path;
72
73 extern gboolean show_cached_as_free; /* Show memory used Cache as free memory */
74
75 extern gboolean full_view;
76
77 extern gint win_width;
78 extern gint win_height;
79
80 const gchar *custom_signal_0;
81 const gchar *custom_signal_1;
82
83 extern int PAGE_SIZE;
84
85 #endif