fix id handling in getRelativeFeedId; allow on-catchup-show-next wrapping (closes #108)
This commit is contained in:
parent
106689b065
commit
d05514a49a
|
@ -62,6 +62,11 @@ function viewfeed(feed, subop, is_cat, subop_param) {
|
||||||
var next_unread_feed = getRelativeFeedId(feedlist,
|
var next_unread_feed = getRelativeFeedId(feedlist,
|
||||||
getActiveFeedId(), "next", true);
|
getActiveFeedId(), "next", true);
|
||||||
|
|
||||||
|
if (!next_unread_feed) {
|
||||||
|
next_unread_feed = getRelativeFeedId(feedlist,
|
||||||
|
-1, "next", true);
|
||||||
|
}
|
||||||
|
|
||||||
var show_next_feed = getInitParam("on_catchup_show_next_feed") == "1";
|
var show_next_feed = getInitParam("on_catchup_show_next_feed") == "1";
|
||||||
|
|
||||||
if (next_unread_feed && show_next_feed && !activeFeedIsCat()) {
|
if (next_unread_feed && show_next_feed && !activeFeedIsCat()) {
|
||||||
|
|
11
functions.js
11
functions.js
|
@ -89,7 +89,9 @@ var notify_effect = false;
|
||||||
function hide_notify() {
|
function hide_notify() {
|
||||||
if (notify_last_doc) {
|
if (notify_last_doc) {
|
||||||
var n = notify_last_doc.getElementById("notify");
|
var n = notify_last_doc.getElementById("notify");
|
||||||
if (browser_has_opacity()) {
|
n.style.display = "none";
|
||||||
|
|
||||||
|
/* if (browser_has_opacity()) {
|
||||||
if (notify_opacity >= 0) {
|
if (notify_opacity >= 0) {
|
||||||
notify_opacity = notify_opacity - 0.1;
|
notify_opacity = notify_opacity - 0.1;
|
||||||
n.style.opacity = notify_opacity;
|
n.style.opacity = notify_opacity;
|
||||||
|
@ -100,7 +102,7 @@ function hide_notify() {
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
n.style.display = "none";
|
n.style.display = "none";
|
||||||
}
|
} */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -976,7 +978,7 @@ function getRelativeFeedId(list, id, direction, unread_only) {
|
||||||
var child = list.childNodes[i];
|
var child = list.childNodes[i];
|
||||||
if (child.id && child.id == "feedCatHolder") {
|
if (child.id && child.id == "feedCatHolder") {
|
||||||
if (child.lastChild) {
|
if (child.lastChild) {
|
||||||
var cr = getRelativeFeedId(child.firstChild, id, direction);
|
var cr = getRelativeFeedId(child.firstChild, id, direction, unread_only);
|
||||||
if (cr) return cr;
|
if (cr) return cr;
|
||||||
}
|
}
|
||||||
} else if (child.id && child.id.match("FEEDR-")) {
|
} else if (child.id && child.id.match("FEEDR-")) {
|
||||||
|
@ -1010,7 +1012,7 @@ function getRelativeFeedId(list, id, direction, unread_only) {
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
var feed = list.ownerDocument.getElementById("FEEDR-" + getActiveFeedId());
|
var feed = list.ownerDocument.getElementById("FEEDR-" + id);
|
||||||
|
|
||||||
if (getInitParam("hide_read_feeds") == 1) {
|
if (getInitParam("hide_read_feeds") == 1) {
|
||||||
unread_only = true;
|
unread_only = true;
|
||||||
|
@ -1047,6 +1049,7 @@ function getRelativeFeedId(list, id, direction, unread_only) {
|
||||||
|
|
||||||
if (e) {
|
if (e) {
|
||||||
if (!unread_only || (unread_only && e.className != "feed" &&
|
if (!unread_only || (unread_only && e.className != "feed" &&
|
||||||
|
e.className != "label" && e.className != "virt" &&
|
||||||
e.className != "error")) {
|
e.className != "error")) {
|
||||||
return e.id.replace("FEEDR-", "");
|
return e.id.replace("FEEDR-", "");
|
||||||
}
|
}
|
||||||
|
|
|
@ -140,7 +140,7 @@ div.postReply div.postIcon {
|
||||||
ul.feedList {
|
ul.feedList {
|
||||||
list-style-type : none;
|
list-style-type : none;
|
||||||
margin : 5px;
|
margin : 5px;
|
||||||
padding : 0px 0px 0px 10px;
|
padding : 0px 0px 0px 5px;
|
||||||
font-size : small;
|
font-size : small;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -161,7 +161,7 @@ ul.feedList li.feedCat a:hover {
|
||||||
|
|
||||||
ul.feedCatList {
|
ul.feedCatList {
|
||||||
list-style-type : none;
|
list-style-type : none;
|
||||||
margin : 0px 0px 0px 20px;
|
margin : 0px 0px 0px 15px;
|
||||||
padding : 0px;
|
padding : 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -343,9 +343,10 @@ td.notifyBox {
|
||||||
}
|
}
|
||||||
|
|
||||||
#dispSwitch {
|
#dispSwitch {
|
||||||
padding : 5px 5px 5px 0px;
|
|
||||||
font-size : x-small;
|
font-size : x-small;
|
||||||
text-align : right;
|
text-align : right;
|
||||||
|
float : right;
|
||||||
|
margin : 5px 5px 0px 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#dispSwitch a {
|
#dispSwitch a {
|
||||||
|
@ -1247,7 +1248,7 @@ div.whiteBox {
|
||||||
right : 5px;
|
right : 5px;
|
||||||
height : 40px;
|
height : 40px;
|
||||||
color : #4684ff;
|
color : #4684ff;
|
||||||
font-size : x-small;
|
font-size : small;
|
||||||
}
|
}
|
||||||
|
|
||||||
#feeds-holder {
|
#feeds-holder {
|
||||||
|
|
Loading…
Reference in New Issue