(trunk web) let rpc tell us the ratio

This commit is contained in:
Kevin Glowacz 2009-07-28 04:52:41 +00:00
parent c816a1e926
commit 588490a232
2 changed files with 4 additions and 3 deletions

View File

@ -294,6 +294,7 @@ Torrent.prototype =
this._leftUntilDone = data.leftUntilDone;
this._download_total = data.downloadedEver;
this._upload_total = data.uploadedEver;
this._upload_ratio = data.uploadRatio
this._download_speed = data.rateDownload;
this._upload_speed = data.rateUpload;
this._peers_connected = data.peersConnected;
@ -449,7 +450,7 @@ Torrent.prototype =
c += ', uploaded ';
c += Math.formatBytes( this._upload_total );
c += ' (Ratio ';
c += Math.ratio( this._upload_total, this._download_total );
c += Math.round(this._upload_ratio*100)/100;
c += ')';
progress_details = c;

View File

@ -107,7 +107,7 @@ TransmissionRemote.prototype =
'isPrivate', 'leechers', 'leftUntilDone', 'name',
'peersConnected', 'peersGettingFromUs', 'peersSendingToUs',
'rateDownload', 'rateUpload', 'seeders', 'sizeWhenDone',
'status', 'swarmSpeed', 'totalSize', 'uploadedEver',
'status', 'swarmSpeed', 'totalSize', 'uploadedEver', 'uploadRatio',
'downloadDir', 'files', 'fileStats' ]
}
};
@ -127,7 +127,7 @@ TransmissionRemote.prototype =
'eta', 'haveUnchecked', 'haveValid', 'leechers', 'leftUntilDone',
'peersConnected', 'peersGettingFromUs', 'peersSendingToUs',
'rateDownload', 'rateUpload', 'recheckProgress', 'seeders',
'sizeWhenDone', 'status', 'swarmSpeed', 'uploadedEver',
'sizeWhenDone', 'status', 'swarmSpeed', 'uploadedEver', 'uploadRatio',
'downloadDir' ]
}
};