|
|
@ -289,9 +289,11 @@ window.addEvent('load', function () { |
|
|
|
onSuccess : function (response) { |
|
|
|
onSuccess : function (response) { |
|
|
|
$('error_div').set('html', ''); |
|
|
|
$('error_div').set('html', ''); |
|
|
|
if (response) { |
|
|
|
if (response) { |
|
|
|
|
|
|
|
var torrentsTableSelectedRows; |
|
|
|
var update_categories = false; |
|
|
|
var update_categories = false; |
|
|
|
var full_update = (response['full_update'] === true); |
|
|
|
var full_update = (response['full_update'] === true); |
|
|
|
if (full_update) { |
|
|
|
if (full_update) { |
|
|
|
|
|
|
|
torrentsTableSelectedRows = torrentsTable.selectedRowsIds(); |
|
|
|
torrentsTable.clear(); |
|
|
|
torrentsTable.clear(); |
|
|
|
category_list = {}; |
|
|
|
category_list = {}; |
|
|
|
} |
|
|
|
} |
|
|
@ -348,6 +350,10 @@ window.addEvent('load', function () { |
|
|
|
updateCategoryList(); |
|
|
|
updateCategoryList(); |
|
|
|
torrentsTableContextMenu.updateCategoriesSubMenu(category_list); |
|
|
|
torrentsTableContextMenu.updateCategoriesSubMenu(category_list); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (full_update) |
|
|
|
|
|
|
|
// re-select previously selected rows
|
|
|
|
|
|
|
|
torrentsTable.reselectRows(torrentsTableSelectedRows); |
|
|
|
} |
|
|
|
} |
|
|
|
clearTimeout(syncMainDataTimer); |
|
|
|
clearTimeout(syncMainDataTimer); |
|
|
|
syncMainDataTimer = syncMainData.delay(syncMainDataTimerPeriod); |
|
|
|
syncMainDataTimer = syncMainData.delay(syncMainDataTimerPeriod); |
|
|
|