[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[giFTcurs-commits] giFTcurs/src misc.c misc.h ui_main.c
From: |
Göran Weinholt |
Subject: |
[giFTcurs-commits] giFTcurs/src misc.c misc.h ui_main.c |
Date: |
Thu, 04 Nov 2004 09:21:16 -0500 |
CVSROOT: /cvsroot/giftcurs
Module name: giFTcurs
Branch:
Changes by: Göran Weinholt <address@hidden> 04/11/04 14:15:14
Modified files:
src : misc.c misc.h ui_main.c
Log message:
Use the right units for the statistics.
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/giftcurs/giFTcurs/src/misc.c.diff?tr1=1.46&tr2=1.47&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/giftcurs/giFTcurs/src/misc.h.diff?tr1=1.17&tr2=1.18&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/giftcurs/giFTcurs/src/ui_main.c.diff?tr1=1.359&tr2=1.360&r1=text&r2=text
Patches:
Index: giFTcurs/src/misc.c
diff -u giFTcurs/src/misc.c:1.46 giFTcurs/src/misc.c:1.47
--- giFTcurs/src/misc.c:1.46 Thu Oct 28 08:54:52 2004
+++ giFTcurs/src/misc.c Thu Nov 4 14:15:12 2004
@@ -18,7 +18,7 @@
* along with giFTcurs; if not, write to the Free Software Foundation,
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
*
- * $Id: misc.c,v 1.46 2004/10/28 08:54:52 weinholt Exp $
+ * $Id: misc.c,v 1.47 2004/11/04 14:15:12 weinholt Exp $
*/
#include "giftcurs.h"
@@ -125,7 +125,7 @@
gc_xdr_uinteger(blob, &tsize);
sharing = !hidden;
stats.own_files = nfiles;
- stats.own_bytes = tsize; /* FIXME: fix the unit */
+ stats.own_bytes = tsize;
event_signal("shared-changed", NULL);
}
@@ -160,7 +160,7 @@
gc_xdr_uinteger(blob, &nfiles);
gc_xdr_uinteger(blob, &tsize);
stats.files += nfiles;
- stats.bytes += tsize; /* FIXME: fix the unit */
+ stats.bytes += tsize;
stats.users += nusers;
} else {
/* FIXME: Network isn't fully connected. */
Index: giFTcurs/src/misc.h
diff -u giFTcurs/src/misc.h:1.17 giFTcurs/src/misc.h:1.18
--- giFTcurs/src/misc.h:1.17 Wed Apr 28 23:03:01 2004
+++ giFTcurs/src/misc.h Thu Nov 4 14:15:12 2004
@@ -18,7 +18,7 @@
* along with giFTcurs; if not, write to the Free Software Foundation,
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
*
- * $Id: misc.h,v 1.17 2004/04/28 23:03:01 weinholt Exp $
+ * $Id: misc.h,v 1.18 2004/11/04 14:15:12 weinholt Exp $
*/
#ifndef _MISC_H
#define _MISC_H
@@ -28,7 +28,8 @@
typedef struct {
/* Gather statistics from this network, or all if set to NULL */
char *network;
- guint64 bytes, own_bytes;
+ guint64 bytes; /* GB */
+ guint64 own_bytes; /* MB */
unsigned int users, files;
/* Our own statistics */
unsigned int own_files;
Index: giFTcurs/src/ui_main.c
diff -u giFTcurs/src/ui_main.c:1.359 giFTcurs/src/ui_main.c:1.360
--- giFTcurs/src/ui_main.c:1.359 Wed Nov 3 21:30:05 2004
+++ giFTcurs/src/ui_main.c Thu Nov 4 14:15:12 2004
@@ -18,7 +18,7 @@
* along with giFTcurs; if not, write to the Free Software Foundation,
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
*
- * $Id: ui_main.c,v 1.359 2004/11/03 21:30:05 weinholt Exp $
+ * $Id: ui_main.c,v 1.360 2004/11/04 14:15:12 weinholt Exp $
*/
#include "giftcurs.h"
@@ -741,8 +741,8 @@
} statlines[] = {
/* *INDENT-OFF* */
{ N_("{%header:B}Users online: {if
users}{%stat-data}{else}{%stat-bad}{endif}{users}"), NULL},
- { N_("{%header:B}Total shared:
{%stat-data}{bytes:bi}B{%stat-box:B}/{%stat-data}{files:b}"), NULL},
- { N_("{%header:B}Local shares: {%stat-data}{if
sharing}{own_bytes:bi}B{%stat-box:B}/{%stat-data}{own_files:b}{else}Hidden{endif}"),
NULL},
+ { N_("{%header:B}Total shared:
{%stat-data}{bytes:Gi}B{%stat-box:B}/{%stat-data}{files:b}"), NULL},
+ { N_("{%header:B}Local shares: {%stat-data}{if
sharing}{own_bytes:Mi}B{%stat-box:B}/{%stat-data}{own_files:b}{else}Hidden{endif}"),
NULL},
{ N_("{%header:B} Shared/user: {%stat-data}{if
users}{shared_per_user:bi}B{else} - {endif}"), NULL},
/* *INDENT-ON* */
};
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [giFTcurs-commits] giFTcurs/src misc.c misc.h ui_main.c,
Göran Weinholt <=