mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-20 15:37:26 -06:00
WebUI: Decrease frequency of updates of property panel
Now that the properties are loaded immediately when the selected torrent or the property tab is changed, the frequency of the updates can be reduced without affecting the user experience. New update intervals: * General: 5 seconds (10 if qBT is not reachable) * Tracker list: 10 seconds (20 if qBT is not reachable) * File list: 5 seconds (10 if qBT is not reachable)
This commit is contained in:
@@ -23,7 +23,7 @@ var loadTorrentData = function() {
|
||||
var current_hash = myTable.getCurrentTorrentHash();
|
||||
if (current_hash == "") {
|
||||
clearData();
|
||||
loadTorrentDataTimer = loadTorrentData.delay(1500);
|
||||
loadTorrentDataTimer = loadTorrentData.delay(5000);
|
||||
return;
|
||||
}
|
||||
// Display hash
|
||||
@@ -35,7 +35,7 @@ var loadTorrentData = function() {
|
||||
method: 'get',
|
||||
onFailure: function() {
|
||||
$('error_div').set('html', '_(qBittorrent client is not reachable)');
|
||||
loadTorrentDataTimer = loadTorrentData.delay(2000);
|
||||
loadTorrentDataTimer = loadTorrentData.delay(10000);
|
||||
},
|
||||
onSuccess: function(data) {
|
||||
$('error_div').set('html', '');
|
||||
@@ -72,7 +72,7 @@ var loadTorrentData = function() {
|
||||
else {
|
||||
clearData();
|
||||
}
|
||||
loadTorrentDataTimer = loadTorrentData.delay(1500);
|
||||
loadTorrentDataTimer = loadTorrentData.delay(5000);
|
||||
}
|
||||
}).send();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user