Commit Graph

587 Commits

Author SHA1 Message Date
Mike Massonnet
7239d4bbb0 Display memory values < 1 MiB
Fixed the MB “typo” and show values for memory in KiB or B if needed.
The threshold for displaying KiB (< 4 MiB) or B (< 9 KiB) are based on
impulse.
2010-05-10 17:57:51 +02:00
Mike Massonnet
9a6cdd2ff3 Filter tree view with show-all-processes
Switched the get_hostname() get_owner_uid() public in task-manager.c,
the owner uid is needed in the tree view class in order to filter out
user processes from others.
2010-05-10 17:03:27 +02:00
Mike Massonnet
99a4a68097 Renamed Show "system" processes to "all" and added a GtkTreeModelFilter
<sigh>
  I started to rename "Show sytem processes" to "Show all processes"
  and included a GtkTreeModelFilter in between the GtkListStore and
  GtkTreeView but nooooo... I had to write private code to sort the
  columns. In fact the GtkTreeViewColumn class assumes the model to
  be sortable but GtkTreeModelFilter is not, although it provides an
  accessor function to the underlying model which is.

  And not to mention that understanding GtkTreeViewColumn is a task
  on its own! Having the code under the hand is the only exit.
</sigh>
2010-05-10 11:29:34 +02:00
Mike Massonnet
1788e3c220 Implement new function pid_is_sleeping()
The function pid_is_sleeping() is implement by the different OS
implementations and returns TRUE or FALSE. It is used in the tree view
context menu to show either the signal Stop or Continue.
2010-05-09 01:34:56 +02:00
Mike Massonnet
07131a81b3 Context menu for sending signals and setting priorities
Base signals and priorities are defined inside the task-manager.h file
to be reused as general values inside the interface. The different OS
implementations have to do the conversion from the enumeration to real
values.
2010-05-09 00:51:46 +02:00
Mike Massonnet
e524915ac7 Several micro fixes on the Linux implementation
Fix one segfault where some processes like “ls” live very briefly and
those may be catched up but at the time to read the cmdline the process
tree already disappeared. Also terminate the cmdline with \0.

I ran the application on my netbook, which doesn't have /proc/<PID>/comm
files... The code has been updated to read the short command from the
buffer.
2010-05-08 14:49:12 +02:00
Mike Massonnet
a7465b61f4 Fix for scanf failing at parsing process names with spaces
The code still uses scanf to parse the stat file, but the process name
is being cleansed so that it never fails. The name is read from the
“comm” file. It is still a truncated version of the name, and will
likely remain for very long like this. There is one solution, but since
the name isn't currently used inside the interface there is no point
wasting time.
2010-05-08 00:10:22 +02:00
Mike Massonnet
553be8eee1 Temporary “fix” of a nasty segfault
On the Linux implementation, when a process name has a space in it the
sscanf function is unable to parse the line properly. This will have to
be changed, but in the meantime ignore such processes and avoid the
segfault, there are going to be Beta releases.
2010-05-07 21:52:46 +02:00
Mike Massonnet
239c5d5064 Enhance performance by updating the GtkTreeModel inside the TaskManager
The code to update the model has been moved inside the XtmTaskManager
class and this in order to enhance performance. In fact all the rows of
the model were udpdated everytime (150~ processes × 9 columns calls on
gtk_list_store_set per seconds) which represented a big CPU hog. Now
that the model is being updated within the same class that pulls the
processes information it is possible to run low check routines and
update only the rows that have updated information.

Also big surprise, the new tasks weren't added, well they did but not
the right data. The pointer's location was copied instead of the
pointer's content.
2010-05-07 21:52:33 +02:00
Mike Massonnet
2506eb50d8 Typo, that's why I hate commit and pushing right behind 2010-05-05 18:02:35 +02:00
Mike Massonnet
3cd86dca3d Well s/jiffles/jiffies/
I was quite sure I had a typo but didn't concider it.
2010-05-05 16:39:51 +02:00
Mike Massonnet
074f5039e1 Calculate CPU usage per process in Linux implementation
Added a utility function that stores old jiffles inside a hash table in
order to be able to provide usage values of system and user time in
percentage.
2010-05-05 16:30:37 +02:00
Mike Massonnet
a02bf69573 Show list of tasks
Provide the list of tasks through a GArray and parse it in main.c to
update the GtkTreeModel.
2010-05-05 09:02:04 +02:00
Mike Massonnet
71d1684696 Add precision to memory/swap and CPU
Switched all the gushort against gfloat data types for the memory, swap
and CPU usages. Show them with a precision of two decimals in the GUI.
2010-05-02 17:03:58 +02:00
Mike Massonnet
4f04ca5cb7 Read information from memory/swap and CPU
This commit is the second of an incremental serie. There will be other
commits with the information about tasks and the support for BSD and
Solaris once things are settled.

The TaskManager class is build with a new source task-manager-linux.c
that provides functions specific to the Linux implementation. It has
functions to read the usage of the memory/swap and the CPU.
2010-05-02 17:00:30 +02:00
Mike Massonnet
9a49bf015a Initial TaskManager class and make room for Swap
Added the TaskManager class to hold system information and tasks.
Currently it provides username and hostname based on POSIX functions.
The Swap is now part of the system information and is being displayed in
the statusbar.
2010-05-02 17:00:30 +02:00
Mike Massonnet
fdaf8b1b49 Rename “Information” to “Preferences” 2010-05-02 17:00:30 +02:00
Mike Massonnet
b83eb75002 Custom statusbar
The statusbar is created since a separate widget class and has three
different labels (settable through properties) for CPU, memory and
number of processes. This makes it more convenient to change one or
another value and it gives a nicer look.
2010-05-02 17:00:24 +02:00
Mike Massonnet
cc6dbd8373 Initial commit of new interface
Changes touching the build:
- Bumped version to 0.5.0.
- Removed dependency on Xfce libs (it only depends on GTK+-2.0.)
- Updated Makefile with new source files.
- Build ChangeLog through a script (remove it from source tree.)

More generally speaking, the interface is build on top of a GtkBuilder
UI definition, with a personal GtkTreeView and a Settings GObject to
update the information shown on the interface on changes. All the code
is being written with GObjects which will make it a lot easier to
separate GUI code and system code.
2010-05-01 15:34:25 +02:00
A S Alam
32068500af l10n: Updated Panjabi (Punjabi) (pa) translation to 100%
New status: 31 messages complete with 0 fuzzies and 0 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-04-06 04:02:26 +02:00
A S Alam
f716753640 l10n: Punjabi Translation Added
New status: 29 messages complete with 0 fuzzies and 2 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-04-04 07:11:01 +02:00
Fabian Nowak
19fdca2a39 l10n: Updated German (de) translation to 100%
New status: 31 messages complete with 0 fuzzies and 0 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-03-28 16:21:25 +02:00
Bauzhan Muftakhidinov
4afeb89d8c l10n: Updated Kazakh (kk) translation to 100%
New status: 31 messages complete with 0 fuzzies and 0 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-03-23 21:47:13 +01:00
Bauzhan Muftakhidinov
3e27d7e525 l10n: New translation into Kazakh
New status: 16 messages complete with 0 fuzzies and 15 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-03-16 06:49:25 +01:00
Akila Wajirasena
cba17348ad l10n: Updated Sinhala (si) translation to 83%
New status: 26 messages complete with 5 fuzzies and 0 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-03-13 18:35:32 +01:00
Akila Wajirasena
86faa3aad9 l10n: Updated Sinhala (si) translation to 67%
New status: 21 messages complete with 3 fuzzies and 7 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-03-13 18:28:56 +01:00
Danishka Navin
e6997f9844 l10n: Added Sinhala (si) translation
New status: 4 messages complete with 0 fuzzies and 27 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-03-13 13:49:46 +01:00
Andres Kovtunos
836500e404 l10n: Updated Russian (ru) translation to 100%
New status: 31 messages complete with 0 fuzzies and 0 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-03-12 18:50:39 +01:00
Gabor Kelemen
573d6e6bb9 l10n: Updated Hungarian (hu) translation to 100%
New status: 31 messages complete with 0 fuzzies and 0 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-02-05 00:44:09 +01:00
Timo Verbeek
9e53a3d1a0 l10n: Updated Dutch (Flemish) (nl) translation to 100%
New status: 31 messages complete with 0 fuzzies and 0 untranslated.

Transmitted-via: Transifex (translations.xfce.org).
2010-01-14 16:22:30 +01:00
Daniel Nylander
2a72838634 l10n: Updates to Swedish (sv) translation
Transmitted-via: Transifex (translations.xfce.org)
2009-12-16 17:08:42 +00:00
Cristian Marchi
00b3880985 l10n: Updates to Italian (it) translation
Transmitted-via: Transifex (translations.xfce.org)
2009-11-21 07:27:45 +00:00
Vlad Vasilev
b61e87a834 l10n: Updates to Russian (ru) translation
Transmitted-via: Transifex (translations.xfce.org)
2009-10-17 19:23:40 +00:00
Vlad Vasilev
9cdcedbac7 l10n: Updates to Russian (ru) translation
Transmitted-via: Transifex (translations.xfce.org)
2009-10-17 19:21:03 +00:00
Rihards Prieditis
52bfa1c051 l10n: Updates to Latvian (lv) translation
Transmitted-via: Transifex (translations.xfce.org)
2009-10-16 14:22:08 +00:00
Leandro Regueiro
530a70be12 l10n: Updates to Galician (gl) translation
Transmitted-via: Transifex (translations.xfce.org)
2009-10-01 15:16:19 +00:00
Mike Massonnet
2ea3ddc135 Small factorize on cmdline reading 2009-09-11 15:33:00 +02:00
Mike Massonnet
e545b2e716 Show command line arguments in Linux 2009-09-09 20:24:24 +02:00
Mike Massonnet
e05fff219f Update Solaris patch from Peter Tribble
Check for the lib kstat in the autoconf script.
Build with the correct file for Solaris in the automake script.
Fixed the xfce_err messages and switched to g_snprintf for the command strings.
Updated the TODO file.
2009-09-08 16:39:30 +02:00
Mike Massonnet
9e43755ce3 Add support for Solaris from Peter Tribble 2009-09-03 19:39:33 +02:00
Mike Massonnet
cf4f5162df Update autotools build
Drop the po/LINGUAS file and substitute them directly inside the
configure script instead.
Update the version tag svn=>git and pass the project URL.
Add a module.xml file for cgit.
2009-08-18 12:09:51 +02:00
Jeff Bailes
5e8cb4e85c l10n: Updates to English (United Kingdom) (en_GB) translation
Transmitted-via: Transifex (translations.xfce.org)
2009-08-18 02:02:20 +00:00
Auke Kok
c1e0cd3e42 l10n: Updates to Dutch (Flemish) (nl) translation
Transmitted-via: Transifex (translations.xfce.org)
2009-08-16 18:08:45 +00:00
Mike Massonnet
fe31b97c0c update goodies translation
(Old svn revision: 7896)
2009-08-08 13:41:32 +00:00
Gabor Kelemen
eee8f99216 2009-07-24 Gabor Kelemen <kelemeng@gnome.hu>
* hu.po: Translation reworked.

(Old svn revision: 7815)
2009-07-24 20:11:00 +00:00
Mike Massonnet
b4f896022f update goodies translation
(Old svn revision: 7639)
2009-06-28 18:26:51 +00:00
Mike Massonnet
a2c401a292 Drop svn:executable bit from po files
(Old svn revision: 7518)
2009-06-09 20:43:09 +00:00
Mike Massonnet
8ec410e609 update goodies translations
(Old svn revision: 7436)
2009-05-29 10:44:34 +00:00
Mike Massonnet
1028923e6d goodies translation update
(Old svn revision: 7213)
2009-04-16 08:20:27 +00:00
Masato Hashimoto
30d63f4b09 * ja.po: Japanese translation update (Masato Hashimoto)
* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)
	* ja.po: Japanese translation update (Masato Hashimoto)

(Old svn revision: 6949)
2009-03-19 15:08:03 +00:00