/home/fernape/Projects/lkmonitor/src/procupdate.h File Reference

#include <gtk/gtk.h>

Go to the source code of this file.

Functions

void update_process_window ()
void update_mm_details (char *mmregion, GtkWindow *window, int pid)


Function Documentation

void update_mm_details ( char *  mmregion,
GtkWindow *  window,
int  pid 
)

Update details of the memory regions

Parameters:
mmregion The mmregion we want to update details for
window The main window
pid The PID of the process

Definition at line 360 of file procupdate.c.

References get_mm_details(), lookup_widget(), mm_details::priv_clean, mm_details::priv_dirty, mm_details::rss, mm_details::sh_clean, mm_details::sh_dirty, and mm_details::size.

Referenced by on_tv_maps_row_activated().

00361 {
00362         struct mm_details details;
00363         GtkLabel *lbl;
00364         GString *gs=g_string_new("");
00365 
00366         get_mm_details(pid,&details,mmregion);
00367 
00368         /* Update the widgets */
00369         lbl=GTK_LABEL(lookup_widget(GTK_WIDGET(window),"lbl_size"));
00370         gtk_label_set_text(lbl,details.size);
00371         lbl=GTK_LABEL(lookup_widget(GTK_WIDGET(window),"lbl_rss"));
00372         gtk_label_set_text(lbl,details.rss);
00373         lbl=GTK_LABEL(lookup_widget(GTK_WIDGET(window),"lbl_shared"));
00374         g_string_printf(gs,"%s / %s",details.sh_clean,details.sh_dirty);
00375         gtk_label_set_text(lbl,gs->str);
00376         lbl=GTK_LABEL(lookup_widget(GTK_WIDGET(window),"lbl_private"));
00377         g_string_printf(gs,"%s / %s",details.priv_clean,details.priv_dirty);
00378         gtk_label_set_text(lbl,gs->str);
00379 
00380 
00381         /* Cleaning up */
00382         g_string_free(gs,TRUE);
00383 }

void update_process_window (  ) 


Generated on Tue Apr 1 22:52:56 2008 for lkmonitor by  doxygen 1.5.1