fix create filter dialog when called from main UI, fix exception_error() parameter position errors
This commit is contained in:
parent
dcbeb0e347
commit
438f2ce922
|
@ -29,7 +29,7 @@ function viewNextFeedPage() {
|
|||
undefined, _feed_cur_page+1);
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "viewFeedGoPage");
|
||||
exception_error("viewFeedGoPage", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
48
functions.js
48
functions.js
|
@ -1193,7 +1193,7 @@ function infobox_submit_callback2(transport) {
|
|||
|
||||
try {
|
||||
// called from prefs, reload tab
|
||||
if (active_tab) {
|
||||
if (typeof active_tab != 'undefined' && active_tab) {
|
||||
selectTab(active_tab, false);
|
||||
}
|
||||
} catch (e) { }
|
||||
|
@ -1249,25 +1249,33 @@ function infobox_callback2(transport) {
|
|||
|
||||
function createFilter() {
|
||||
|
||||
var form = document.forms['filter_add_form'];
|
||||
var reg_exp = form.reg_exp.value;
|
||||
try {
|
||||
|
||||
if (reg_exp == "") {
|
||||
alert(__("Can't add filter: nothing to match on."));
|
||||
return false;
|
||||
}
|
||||
|
||||
var query = Form.serialize("filter_add_form");
|
||||
|
||||
// we can be called from some other tab in Prefs
|
||||
if (active_tab) active_tab = "filterConfig";
|
||||
|
||||
new Ajax.Request("backend.php?" + query, {
|
||||
onComplete: function (transport) {
|
||||
infobox_submit_callback2(transport);
|
||||
} });
|
||||
var form = document.forms['filter_add_form'];
|
||||
var reg_exp = form.reg_exp.value;
|
||||
|
||||
return true;
|
||||
if (reg_exp == "") {
|
||||
alert(__("Can't add filter: nothing to match on."));
|
||||
return false;
|
||||
}
|
||||
|
||||
var query = Form.serialize("filter_add_form");
|
||||
|
||||
// we can be called from some other tab in Prefs
|
||||
if (typeof active_tab != 'undefined' && active_tab) {
|
||||
active_tab = "filterConfig";
|
||||
}
|
||||
|
||||
new Ajax.Request("backend.php?" + query, {
|
||||
onComplete: function (transport) {
|
||||
infobox_submit_callback2(transport);
|
||||
} });
|
||||
|
||||
return true;
|
||||
|
||||
} catch (e) {
|
||||
exception_error("createFilter", e);
|
||||
}
|
||||
}
|
||||
|
||||
function toggleSubmitNotEmpty(e, submit_id) {
|
||||
|
@ -1459,7 +1467,7 @@ function filterDlgCheckAction(sender) {
|
|||
}
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "filterDlgCheckAction");
|
||||
exception_error("filterDlgCheckAction", e);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -1636,7 +1644,7 @@ function focus_element(id) {
|
|||
var e = document.getElementById(id);
|
||||
if (e) e.focus();
|
||||
} catch (e) {
|
||||
exception_error(e, "focus_element");
|
||||
exception_error("focus_element", e);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -785,7 +785,7 @@ function toggle_feedlist() {
|
|||
// queue: { position: 'end', scope: 'FLFADEQ', limit: 1 }});
|
||||
}
|
||||
} catch (e) {
|
||||
exception_error(e, "toggle_feedlist");
|
||||
exception_error("toggle_feedlist", e);
|
||||
}
|
||||
} */
|
||||
|
||||
|
@ -848,7 +848,7 @@ function collapse_feedlist() {
|
|||
setCookie("ttrss_vf_fclps", "1");
|
||||
}
|
||||
} catch (e) {
|
||||
exception_error(e, "toggle_feedlist");
|
||||
exception_error("toggle_feedlist", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -877,7 +877,7 @@ function adjustArticleScore(id, score) {
|
|||
|
||||
}
|
||||
} catch (e) {
|
||||
exception_error(e, "adjustArticleScore");
|
||||
exception_error("adjustArticleScore", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
18
viewfeed.js
18
viewfeed.js
|
@ -788,7 +788,7 @@ function moveToPost(mode) {
|
|||
} */
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "moveToPost");
|
||||
exception_error("moveToPost", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -820,7 +820,7 @@ function toggleSelected(id) {
|
|||
row.className = nc;
|
||||
}
|
||||
} catch (e) {
|
||||
exception_error(e, "toggleSelected");
|
||||
exception_error("toggleSelected", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -831,7 +831,7 @@ function toggleUnread_afh(effect) {
|
|||
elem.style.backgroundColor = "";
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "toggleUnread_afh");
|
||||
exception_error("toggleUnread_afh", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1315,7 +1315,7 @@ function editTagsInsert() {
|
|||
found_tags.selectedIndex = 0;
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "editTagsInsert");
|
||||
exception_error("editTagsInsert", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1349,7 +1349,7 @@ function cdmArticleIsBelowViewport(id) {
|
|||
}
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "cdmArticleIsVisible");
|
||||
exception_error("cdmArticleIsVisible", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1369,7 +1369,7 @@ function cdmArticleIsAboveViewport(id) {
|
|||
}
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "cdmArticleIsVisible");
|
||||
exception_error("cdmArticleIsVisible", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1383,7 +1383,7 @@ function cdmScrollToArticleId(id) {
|
|||
ctr.scrollTop = e.offsetTop;
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "cdmScrollToArticleId");
|
||||
exception_error("cdmScrollToArticleId", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1413,7 +1413,7 @@ function cdmArticleIsActuallyVisible(id) {
|
|||
return false;
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "cdmArticleIsVisible");
|
||||
exception_error("cdmArticleIsVisible", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1491,7 +1491,7 @@ function cdmWatchdog() {
|
|||
_cdm_wd_timeout = window.setTimeout("cdmWatchdog()", 4000);
|
||||
|
||||
} catch (e) {
|
||||
exception_error(e, "cdmWatchdog");
|
||||
exception_error("cdmWatchdog", e);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue