Esempio n. 1
0
static void serverstats_selected(GtkWidget * container)
{
    if (serverstats_sw == NULL)
    {
        serverstats_init();
    }
    serverstats_update();
    gtk_box_pack_start(GTK_BOX(container), serverstats_sw,TRUE, TRUE, 0);
    gtk_widget_show(serverstats_sw);
    if (timeout_source)
        g_source_remove(timeout_source);
    timeout_source = g_timeout_add_seconds(5, (GSourceFunc) serverstats_update, NULL);
}
Esempio n. 2
0
static void serverstats_selected(GtkWidget * container)
{
	if (serverstats_sw == NULL)
	{
		serverstats_init();
	}
	serverstats_update();
	gtk_container_add(GTK_CONTAINER(container), serverstats_sw);
	gtk_widget_show(serverstats_sw);
	if (timeout_source)
		g_source_remove(timeout_source);
	timeout_source = g_timeout_add_seconds(5, (GSourceFunc) serverstats_update, NULL);
}