- Disabled file prioritizing for seeding torrents

- Added file prioritizing to Web UI
This commit is contained in:
Christophe Dumez 2009-11-24 15:38:47 +00:00
parent d4524993ee
commit aeb2c06e0f
10 changed files with 106 additions and 52 deletions

View file

@ -470,7 +470,9 @@ void QTorrentHandle::set_max_connections(int val) {
}
void QTorrentHandle::prioritize_files(std::vector<int> v) {
// Does not do anything for seeding torrents
Q_ASSERT(h.is_valid());
Q_ASSERT(v.size() == (unsigned int)h.get_torrent_info().num_files());
h.prioritize_files(v);
}
@ -528,6 +530,7 @@ void QTorrentHandle::move_storage(QString new_path) const {
void QTorrentHandle::file_priority(int index, int priority) const {
Q_ASSERT(h.is_valid());
if(is_seed()) return;
h.file_priority(index, priority);
}