Added start/stop keys.

Added more extensive download status information where only tracker
status used to be.


git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@279 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
rakshasa
2005-02-15 21:59:35 +00:00
parent f348196f2e
commit 46120cbb30
16 changed files with 182 additions and 71 deletions
+31
View File
@@ -0,0 +1,31 @@
#include "config.h"
#include <sstream>
#include "core/download.h"
#include "utils.h"
namespace display {
std::string
print_download_status(core::Download* d) {
std::stringstream str;
if (d->get_download().is_hash_checking()) {
str << "Checking hash";
} else if (d->get_download().is_tracker_busy()) {
str << "Tracker: Connecting";
} else if (!d->get_download().is_active()) {
str << "Inactive";
} else {
str << "Tracker: " << d->get_tracker_msg();
}
return str.str();
}
}