- Removed a useless function

- Stop resfreshing trackers errors in torrent properties because this is annoying when you're trying to read them
This commit is contained in:
Christophe Dumez 2007-07-31 09:17:59 +00:00
parent 816a3c8784
commit 99a58b9208
3 changed files with 2 additions and 16 deletions

View file

@ -771,7 +771,8 @@ void bittorrent::setUploadRateLimit(int rate){
// This function will apply to same ratio to all torrents
void bittorrent::setGlobalRatio(float ratio){
std::vector<torrent_handle> handles = s->get_torrents();
for(unsigned int i=0; i<handles.size(); ++i){
unsigned int nbHandles = handles.size();
for(unsigned int i=0; i<nbHandles; ++i){
torrent_handle h = handles[i];
if(!h.is_valid()){
qDebug("/!\\ Error: Invalid handle");
@ -1085,19 +1086,6 @@ std::vector<torrent_handle> bittorrent::getTorrentHandles() const{
return s->get_torrents();
}
// Return a vector with all finished torrent handles in it
QList<torrent_handle> bittorrent::getFinishedTorrentHandles() const{
QList<torrent_handle> finished;
std::vector<torrent_handle> handles;
for(unsigned int i=0; i<handles.size(); ++i){
torrent_handle h = handles[i];
if(h.is_seed()){
finished << h;
}
}
return finished;
}
QStringList bittorrent::getUncheckedTorrentsList() const{
return torrentsUnchecked;
}

View file

@ -72,7 +72,6 @@ class bittorrent : public QObject{
bool isDHTEnabled() const;
float getPayloadDownloadRate() const;
float getPayloadUploadRate() const;
QList<torrent_handle> getFinishedTorrentHandles() const;
session_status getSessionStatus() const;
int getListenPort() const;
QStringList getTorrentsToPauseAfterChecking() const;

View file

@ -466,7 +466,6 @@ void properties::updateInfos(){
// torrent was removed, closing properties
close();
}
loadTrackersErrors();
// Update current tracker
torrent_status torrentStatus = h.status();
QString tracker = QString(torrentStatus.current_tracker.c_str()).trimmed();