]> granicus.if.org Git - transmission/commitdiff
(trunk) #1408 (Total downloading and seeding time per torrent) -- add to rpc spec...
authorCharles Kerr <charles@transmissionbt.com>
Mon, 27 Dec 2010 02:01:25 +0000 (02:01 +0000)
committerCharles Kerr <charles@transmissionbt.com>
Mon, 27 Dec 2010 02:01:25 +0000 (02:01 +0000)
daemon/remote.c
extras/rpc-spec.txt

index c08fea966f99ae669d27fd109f9ef99d5324c0ec..82d65a997ec7e58593623791cace9f090f8f1006 100644 (file)
@@ -667,6 +667,8 @@ static const char * details_keys[] = {
     "rateDownload",
     "rateUpload",
     "recheckProgress",
+    "secondsDownloading",
+    "secondsSeeding",
     "seedRatioMode",
     "seedRatioLimit",
     "sizeWhenDone",
@@ -845,6 +847,10 @@ printDetails( tr_benc * top )
 
             if( tr_bencDictFindInt( t, "eta", &i ) )
                 printf( "  ETA: %s\n", tr_strltime( buf, i, sizeof( buf ) ) );
+            if( tr_bencDictFindInt( t, "secondsDownloading", &i ) && ( i > 0 ) )
+                printf( "  Time Downloading: %s\n", tr_strltime( buf, i, sizeof( buf ) ) );
+            if( tr_bencDictFindInt( t, "secondsSeeding", &i ) && ( i > 0 ) )
+                printf( "  Time Seeding: %s\n", tr_strltime( buf, i, sizeof( buf ) ) );
             if( tr_bencDictFindInt( t, "rateDownload", &i ) )
                 printf( "  Download Speed: %s\n", tr_formatter_speed_KBps( buf, i/(double)tr_speed_K, sizeof( buf ) ) );
             if( tr_bencDictFindInt( t, "rateUpload", &i ) )
index fcc0bbb89347625b57a38d394a60208af268a634..0e9088e38483276b0fd58144244f3837302b3bb0 100644 (file)
    rateDownload (B/s)          | number                      | tr_stat
    rateUpload (B/s)            | number                      | tr_stat
    recheckProgress             | double                      | tr_stat
+   secondsDownloading          | number                      | tr_stat
+   secondsSeeding              | number                      | tr_stat
    seedIdleLimit               | number                      | tr_torrent
    seedIdleMode                | number                      | tr_inactvelimit
    seedRatioLimit              | double                      | tr_torrent