fix unsubscribeFeed behaving improperly in preferences
This commit is contained in:
parent
02b289d661
commit
78bcd2c44c
30
functions.js
30
functions.js
|
@ -2156,3 +2156,33 @@ function quickAddFilter() {
|
|||
displayDlg('quickAddFilter', '',
|
||||
function () {document.forms['filter_add_form'].reg_exp.focus();});
|
||||
}
|
||||
|
||||
function unsubscribeFeed(feed_id, title) {
|
||||
|
||||
var msg = __("Unsubscribe from %s?").replace("%s", title);
|
||||
|
||||
if (title == undefined || confirm(msg)) {
|
||||
notify_progress("Removing feed...");
|
||||
|
||||
var query = "?op=pref-feeds&quiet=1&subop=remove&ids=" + feed_id;
|
||||
|
||||
new Ajax.Request("backend.php", {
|
||||
parameters: query,
|
||||
onComplete: function(transport) {
|
||||
|
||||
closeInfoBox();
|
||||
|
||||
if (inPreferences()) {
|
||||
updateFeedList();
|
||||
} else {
|
||||
dlg_frefresh_callback(transport, feed_id);
|
||||
}
|
||||
|
||||
} });
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
4
prefs.js
4
prefs.js
|
@ -1845,7 +1845,7 @@ function removeFilter(id, title) {
|
|||
return false;
|
||||
}
|
||||
|
||||
function unsubscribeFeed(id, title) {
|
||||
/*function unsubscribeFeed(id, title) {
|
||||
|
||||
try {
|
||||
|
||||
|
@ -1874,7 +1874,7 @@ function unsubscribeFeed(id, title) {
|
|||
|
||||
return false;
|
||||
|
||||
}
|
||||
} */
|
||||
|
||||
function feedsEditSave() {
|
||||
try {
|
||||
|
|
21
tt-rss.js
21
tt-rss.js
|
@ -626,27 +626,6 @@ function quickMenuGo(opid) {
|
|||
}
|
||||
}
|
||||
|
||||
function unsubscribeFeed(feed_id, title) {
|
||||
|
||||
|
||||
var msg = __("Unsubscribe from %s?").replace("%s", title);
|
||||
|
||||
if (title == undefined || confirm(msg)) {
|
||||
notify_progress("Removing feed...");
|
||||
|
||||
var query = "?op=pref-feeds&quiet=1&subop=remove&ids=" + feed_id;
|
||||
|
||||
new Ajax.Request("backend.php", {
|
||||
parameters: query,
|
||||
onComplete: function(transport) {
|
||||
dlg_frefresh_callback(transport, feed_id);
|
||||
} });
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
function updateFeedTitle(t) {
|
||||
active_title_text = t;
|
||||
updateTitle();
|
||||
|
|
Loading…
Reference in New Issue