var debug_mode_enabled = false;
var xmlhttp_rpc = Ajax.getTransport();
+/* add method to remove element from array */
+
+Array.prototype.remove = function(s) {
+ for (var i=0; i < this.length; i++) {
+ if (s == this[i]) this.splice(i, 1);
+ }
+}
+
function browser_has_opacity() {
return navigator.userAgent.match("Gecko") != null ||
navigator.userAgent.match("Opera") != null;
}
}
+function tSR(sender) {
+ return toggleSelectRow(sender);
+}
function toggleSelectRow(sender) {
var parent_row = sender.parentNode.parentNode;
if (direction == "prev") {
for (i = list.childNodes.length-1; i >= 0; i--) {
var child = list.childNodes[i];
- if (child.id == "feedCatHolder") {
+ if (child.id == "feedCatHolder" && child.className != "invisible") {
if (child.firstChild) {
var cr = getRelativeFeedId(child.firstChild, id, direction);
if (cr) return cr;
if (getInitParam("hide_read_feeds") == 1) {
if (child.className != "feed") {
- alert(child.className);
+// alert(child.className);
return child.id.replace('FEEDR-', '');
}
} else {
if (e) {
if (!unread_only || (unread_only && e.className != "feed" &&
e.className.match("feed"))) {
- return e.id.replace("FEEDR-", "");
+ if (e.parentNode.parentNode && e.parentNode.parentNode.className
+ != "invisible") {
+ return e.id.replace("FEEDR-", "");
+ }
}
}
}
if (e) {
if (!unread_only || (unread_only && e.className != "feed" &&
e.className.match("feed"))) {
- return e.id.replace("FEEDR-", "");
+ if (e.parentNode.parentNode && e.parentNode.parentNode.className
+ != "invisible") {
+ return e.id.replace("FEEDR-", "");
+ }
}
}
}
}
function closeInfoBox(cleanup) {
+
+ if (!is_msie() && !getInitParam("infobox_disable_overlay")) {
+ var overlay = document.getElementById("dialog_overlay");
+ if (overlay) {
+ overlay.style.display = "none";
+ }
+ }
+
var box = document.getElementById('infoBox');
var shadow = document.getElementById('infoBoxShadow');
function infobox_callback() {
if (xmlhttp.readyState == 4) {
+
+ if (!is_msie() && !getInitParam("infobox_disable_overlay")) {
+ var overlay = document.getElementById("dialog_overlay");
+ if (overlay) {
+ overlay.style.display = "block";
+ }
+ }
+
var box = document.getElementById('infoBox');
var shadow = document.getElementById('infoBoxShadow');
if (box) {
}
}
+function helpbox_callback() {
+ if (xmlhttp.readyState == 4) {
+ var box = document.getElementById('helpBox');
+ var shadow = document.getElementById('helpBoxShadow');
+ if (box) {
+ box.innerHTML=xmlhttp.responseText;
+ if (shadow) {
+ shadow.style.display = "block";
+ } else {
+ box.style.display = "block";
+ }
+ }
+ notify("");
+ }
+}
+
function addFilter() {
if (!xmlhttp_ready(xmlhttp)) {
function storeInitParam(key, value) {
debug("<b>storeInitParam is OBSOLETE: " + key + " => " + value + "</b>");
+ init_params[key] = value;
}
function fatalError(code, message) {
exception_error("logoutUser", e);
}
}
+
+// this only searches loaded headlines list, not in CDM
+function getRelativePostIds(id) {
+
+ debug("getRelativePostIds: " + id);
+
+ var ids = new Array();
+ var container = document.getElementById("headlinesList");
+
+ if (container) {
+ var rows = container.rows;
+
+ for (var i = 0; i < rows.length; i++) {
+ var r_id = rows[i].id.replace("RROW-", "");
+
+ if (r_id == id) {
+ if (i > 0) ids.push(rows[i-1].id.replace("RROW-", ""));
+ if (i > 1) ids.push(rows[i-2].id.replace("RROW-", ""));
+ if (i > 2) ids.push(rows[i-3].id.replace("RROW-", ""));
+
+ if (i < rows.length-1) ids.push(rows[i+1].id.replace("RROW-", ""));
+ if (i < rows.length-2) ids.push(rows[i+2].id.replace("RROW-", ""));
+ if (i < rows.length-3) ids.push(rows[i+3].id.replace("RROW-", ""));
+
+ return ids;
+ }
+ }
+ }
+
+ return false;
+}