mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-15 20:55:56 +00:00
cdm tweaks, misc fixes
This commit is contained in:
17
backend.php
17
backend.php
@@ -451,9 +451,11 @@
|
|||||||
|
|
||||||
if ($line["marked"] == "t" || $line["marked"] == "1") {
|
if ($line["marked"] == "t" || $line["marked"] == "1") {
|
||||||
$marked_pic = "<img id=\"FMARKPIC-$id\" src=\"images/mark_set.png\"
|
$marked_pic = "<img id=\"FMARKPIC-$id\" src=\"images/mark_set.png\"
|
||||||
|
class=\"markedPic\"
|
||||||
alt=\"Reset mark\" onclick='javascript:toggleMark($id)'>";
|
alt=\"Reset mark\" onclick='javascript:toggleMark($id)'>";
|
||||||
} else {
|
} else {
|
||||||
$marked_pic = "<img id=\"FMARKPIC-$id\" src=\"images/mark_unset.png\"
|
$marked_pic = "<img id=\"FMARKPIC-$id\" src=\"images/mark_unset.png\"
|
||||||
|
class=\"markedPic\"
|
||||||
alt=\"Set mark\" onclick='javascript:toggleMark($id)'>";
|
alt=\"Set mark\" onclick='javascript:toggleMark($id)'>";
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -534,10 +536,7 @@
|
|||||||
|
|
||||||
print "<div class=\"cdmHeader\">";
|
print "<div class=\"cdmHeader\">";
|
||||||
|
|
||||||
print "<div style=\"float : right\">$updated_fmt
|
print "<div class=\"articleUpdated\">$updated_fmt</div>";
|
||||||
<!-- <a class=\"cdmToggleLink\"
|
|
||||||
href=\"javascript:toggleUnread($id)\">Toggle unread</a> -->
|
|
||||||
</div>";
|
|
||||||
|
|
||||||
print "<a class=\"title\"
|
print "<a class=\"title\"
|
||||||
onclick=\"javascript:toggleUnread($id, 0)\"
|
onclick=\"javascript:toggleUnread($id, 0)\"
|
||||||
@@ -553,10 +552,10 @@
|
|||||||
|
|
||||||
print "<div class=\"cdmContent\">" . $line["content_preview"] . "</div><br clear=\"all\">";
|
print "<div class=\"cdmContent\">" . $line["content_preview"] . "</div><br clear=\"all\">";
|
||||||
|
|
||||||
print "<div style=\"float : right\">$marked_pic</div>
|
print "<div class=\"cdmFooter\">";
|
||||||
<div class=\"cdmFooter\">";
|
|
||||||
|
print "$marked_pic";
|
||||||
|
|
||||||
|
|
||||||
print "<input type=\"checkbox\" onclick=\"toggleSelectRowById(this,
|
print "<input type=\"checkbox\" onclick=\"toggleSelectRowById(this,
|
||||||
'RROW-$id')\" class=\"feedCheckBox\" id=\"RCHK-$id\">";
|
'RROW-$id')\" class=\"feedCheckBox\" id=\"RCHK-$id\">";
|
||||||
|
|
||||||
@@ -570,8 +569,10 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
$tags_str = preg_replace("/, $/", "", $tags_str);
|
$tags_str = preg_replace("/, $/", "", $tags_str);
|
||||||
|
|
||||||
|
if ($tags_str == "") $tags_str = "no tags";
|
||||||
|
|
||||||
print " $tags_str <a title=\"Edit tags for this article\"
|
print " $tags_str <a title=\"Edit tags for this article\"
|
||||||
href=\"javascript:editArticleTags($id, $feed_id, true)\">(+)</a>";
|
href=\"javascript:editArticleTags($id, $feed_id, true)\">(+)</a>";
|
||||||
|
|
||||||
print "</div>";
|
print "</div>";
|
||||||
|
|||||||
10
feedlist.js
10
feedlist.js
@@ -37,7 +37,11 @@ function viewFeedGoPage(i) {
|
|||||||
function viewfeed(feed, subop, is_cat, subop_param, skip_history, offset) {
|
function viewfeed(feed, subop, is_cat, subop_param, skip_history, offset) {
|
||||||
try {
|
try {
|
||||||
|
|
||||||
if (!offset) page_offset = 0;
|
//if (!offset) page_offset = 0;
|
||||||
|
|
||||||
|
if (offset != undefined) {
|
||||||
|
page_offset = offset;
|
||||||
|
}
|
||||||
|
|
||||||
enableHotkeys();
|
enableHotkeys();
|
||||||
|
|
||||||
@@ -106,8 +110,8 @@ function viewfeed(feed, subop, is_cat, subop_param, skip_history, offset) {
|
|||||||
query = query + "&cat=1";
|
query = query + "&cat=1";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (offset) {
|
if (page_offset != 0) {
|
||||||
query = query + "&skip=" + offset;
|
query = query + "&skip=" + page_offset;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (navigator.userAgent.match("Opera")) {
|
if (navigator.userAgent.match("Opera")) {
|
||||||
|
|||||||
@@ -949,7 +949,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
$feed = "<a title=\"$link_title\" id=\"FEEDL-$feed_id\"
|
$feed = "<a title=\"$link_title\" id=\"FEEDL-$feed_id\"
|
||||||
href=\"javascript:viewfeed('$feed_id', '', false);\">$feed_title</a>";
|
href=\"javascript:viewfeed('$feed_id', '', false, '', false, 0);\">$feed_title</a>";
|
||||||
|
|
||||||
print "<li id=\"FEEDR-$feed_id\" class=\"$class\">";
|
print "<li id=\"FEEDR-$feed_id\" class=\"$class\">";
|
||||||
if (get_pref($link, 'ENABLE_FEED_ICONS')) {
|
if (get_pref($link, 'ENABLE_FEED_ICONS')) {
|
||||||
|
|||||||
11
tt-rss.css
11
tt-rss.css
@@ -806,6 +806,16 @@ div.cdmFooter {
|
|||||||
padding-top : 5px;
|
padding-top : 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
div.cdmFooter img.markedPic {
|
||||||
|
width : 16px;
|
||||||
|
height : 16px;
|
||||||
|
float : right;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.cdmHeader div.articleUpdated {
|
||||||
|
float : right;
|
||||||
|
}
|
||||||
|
|
||||||
div.cdmFooter input, div.cdmHeader input, div.cdmFooter img {
|
div.cdmFooter input, div.cdmHeader input, div.cdmFooter img {
|
||||||
margin : 0px;
|
margin : 0px;
|
||||||
}
|
}
|
||||||
@@ -1416,3 +1426,4 @@ ul.headlineDropdownMenu ul li:hover {
|
|||||||
background-color : #f0f0f0;
|
background-color : #f0f0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
15
viewfeed.js
15
viewfeed.js
@@ -553,8 +553,6 @@ function cdmWatchdog() {
|
|||||||
|
|
||||||
var ctr = document.getElementById("headlinesInnerContainer");
|
var ctr = document.getElementById("headlinesInnerContainer");
|
||||||
|
|
||||||
if (!ctr.hasChildNodes()) return;
|
|
||||||
|
|
||||||
var ids = new Array();
|
var ids = new Array();
|
||||||
|
|
||||||
var e = ctr.firstChild;
|
var e = ctr.firstChild;
|
||||||
@@ -583,6 +581,15 @@ function cdmWatchdog() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// method 2: article bottom is visible and is in upper 1/2 of the viewport
|
||||||
|
|
||||||
|
/* if (e.offsetTop + e.offsetHeight >= ctr.scrollTop &&
|
||||||
|
e.offsetTop + e.offsetHeight <= ctr.scrollTop + ctr.offsetHeight/2) {
|
||||||
|
|
||||||
|
ids.push(e.id.replace("RROW-", ""));
|
||||||
|
|
||||||
|
} */
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
e = e.nextSibling;
|
e = e.nextSibling;
|
||||||
@@ -604,11 +611,11 @@ function cdmWatchdog() {
|
|||||||
|
|
||||||
xmlhttp_rpc.open("GET", query, true);
|
xmlhttp_rpc.open("GET", query, true);
|
||||||
xmlhttp_rpc.onreadystatechange=all_counters_callback;
|
xmlhttp_rpc.onreadystatechange=all_counters_callback;
|
||||||
xmlhttp_rpc.send(null);
|
xmlhttp_rpc.send(null);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_cdm_wd_timeout = window.setTimeout("cdmWatchdog()", 5000);
|
_cdm_wd_timeout = window.setTimeout("cdmWatchdog()", 4000);
|
||||||
|
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
exception_error(e, "cdmWatchdog");
|
exception_error(e, "cdmWatchdog");
|
||||||
|
|||||||
Reference in New Issue
Block a user