From e22eb7c68b199faa822aedbfe91c9263d53dde91 Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Sun, 10 Aug 2008 19:11:59 +0000 Subject: [PATCH] (gtk) show "remaining time unknown" instead of "data not fully available" --- gtk/torrent-cell-renderer.c | 6 ++---- gtk/tr-torrent.c | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/gtk/torrent-cell-renderer.c b/gtk/torrent-cell-renderer.c index 74d417354..9db69f0df 100644 --- a/gtk/torrent-cell-renderer.c +++ b/gtk/torrent-cell-renderer.c @@ -83,10 +83,8 @@ getProgressString( const tr_info * info, const tr_stat * torStat ) const int eta = torStat->eta; GString * gstr = g_string_new( str ); g_string_append( gstr, " - " ); - if( eta == TR_ETA_NOT_AVAIL ) - g_string_append( gstr, _( "Data not fully available" ) ); - else if( eta == TR_ETA_UNKNOWN ) - g_string_append( gstr, _( "Stalled" ) ); + if( eta < 0 ) + g_string_append( gstr, _( "Remaining time unknown" ) ); else { char timestr[128]; tr_strltime( timestr, eta, sizeof( timestr ) ); diff --git a/gtk/tr-torrent.c b/gtk/tr-torrent.c index 3c0fecf9d..4b3cb9787 100644 --- a/gtk/tr-torrent.c +++ b/gtk/tr-torrent.c @@ -250,10 +250,8 @@ tr_torrent_status_str ( TrTorrent * gtor ) case TR_STATUS_DOWNLOAD: - if( eta == TR_ETA_NOT_AVAIL ) - top = g_strdup_printf( _("Data not fully available (%.1f%%)" ), prog ); - else if( eta == TR_ETA_UNKNOWN ) - top = g_strdup_printf( _( "Stalled (%.1f%%)" ), prog ); + if( eta < 0 ) + top = g_strdup_printf( _("Remaining time unknown (%.1f%%)" ), prog ); else { char timestr[128]; tr_strltime( timestr, eta, sizeof( timestr ) );