Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Globals | Related Pages

nodes.c File Reference

#include "gtk/gui.h"
#include "interface-glade.h"
#include "gtk/gtk-missing.h"
#include "gtk/misc.h"
#include "gtk/nodes_common.h"
#include "gtk/nodes.h"
#include "gtk/notebooks.h"
#include "gtk/columns.h"
#include "if/gui_property_priv.h"
#include "if/gui_property.h"
#include "if/bridge/ui2c.h"
#include "lib/glib-missing.h"
#include "lib/iso3166.h"
#include "lib/tm.h"
#include "lib/utf8.h"
#include "lib/override.h"

Defines

#define UPDATE_MIN   300 /**< Update screen every 5 minutes at least */
 Update screen every 5 minutes at least.


Functions

 RCSID ("$Id:nodes.c, v 1.21 2005/12/17 09:25:44 daichik Exp $")
void nodes_gui_update_node_info (gnet_node_info_t *n, gint row)
 Update the row with the given nodeinfo.

void nodes_gui_update_node_flags (gnet_node_t n, gnet_node_flags_t *flags, gint row)
 Updates the flags for given node and row.

gboolean nodes_gui_is_visible (void)
void nodes_gui_node_removed (gnet_node_t n)
 Callback: called when a node is removed from the backend.

void nodes_gui_node_added (gnet_node_t n)
 Callback: called when a node is added from the backend.

void nodes_gui_node_info_changed (gnet_node_t n)
 Callback: called when node information was changed by the backend.

void nodes_gui_node_flags_changed (gnet_node_t n)
 Callback invoked when the node's user-visible flags are changed.

void nodes_gui_early_init (void)
 Initialized the widgets.

void nodes_gui_init (void)
 Initialize the nodes controller.

void nodes_gui_shutdown (void)
 Unregister callbacks in the backend and clean up.

void nodes_gui_remove_node (gnet_node_t n)
 Removes all references to the given node handle in the gui.

void nodes_gui_add_node (gnet_node_info_t *n)
 Adds the given node to the gui.

void nodes_gui_update_nodes_display (time_t now)
 Update all the nodes at the same time.


Variables

GHashTable * ht_node_info_changed = NULL
GHashTable * ht_node_flags_changed = NULL


Define Documentation

#define UPDATE_MIN   300 /**< Update screen every 5 minutes at least */
 

Update screen every 5 minutes at least.


Function Documentation

void nodes_gui_add_node gnet_node_info_t n  ) 
 

Adds the given node to the gui.

void nodes_gui_early_init void   ) 
 

Initialized the widgets.

void nodes_gui_init void   ) 
 

Initialize the nodes controller.

Register callbacks in the backend.

gboolean nodes_gui_is_visible void   )  [static]
 

void nodes_gui_node_added gnet_node_t  n  )  [static]
 

Callback: called when a node is added from the backend.

Adds the node to the gui.

void nodes_gui_node_flags_changed gnet_node_t  n  )  [static]
 

Callback invoked when the node's user-visible flags are changed.

This schedules an update of the node information in the gui at the next tick.

void nodes_gui_node_info_changed gnet_node_t  n  )  [static]
 

Callback: called when node information was changed by the backend.

This schedules an update of the node information in the gui at the next tick.

void nodes_gui_node_removed gnet_node_t  n  )  [static]
 

Callback: called when a node is removed from the backend.

Removes all references to the node from the frontend.

void nodes_gui_remove_node gnet_node_t  n  ) 
 

Removes all references to the given node handle in the gui.

void nodes_gui_shutdown void   ) 
 

Unregister callbacks in the backend and clean up.

void nodes_gui_update_node_flags gnet_node_t  n,
gnet_node_flags_t flags,
gint  row
[static]
 

Updates the flags for given node and row.

void nodes_gui_update_node_info gnet_node_info_t n,
gint  row
[static]
 

Update the row with the given nodeinfo.

If row is -1 the row number is determined by the node_handle contained in the gnet_node_info_t.

void nodes_gui_update_nodes_display time_t  now  ) 
 

Update all the nodes at the same time.

@

Bug:
FIXME: We should remember for every node when it was last updated and only refresh every node at most once every second. This information should be kept in a struct pointed to by the row user_data and should be automatically freed when removing the row (see upload stats code).

RCSID "$Id:nodes.  c,
v 1.21 2005/12/17 09:25:44 daichik Exp $" 
 


Variable Documentation

GHashTable* ht_node_flags_changed = NULL [static]
 

GHashTable* ht_node_info_changed = NULL [static]
 


Generated on Sun Feb 12 10:50:05 2006 for Gtk-Gnutella by doxygen 1.3.6