diff options
author | Art4 <[email protected]> | 2015-02-19 23:17:43 +0100 |
---|---|---|
committer | Art4 <[email protected]> | 2015-02-19 23:17:43 +0100 |
commit | d9c042c4c536f1afbf206aeea09b0b127b7b6418 (patch) | |
tree | 9d7ef18c6d9d4c8f8f4d1c9a5dbfceeb9fd5acf4 /js/viewfeed.js | |
parent | cf42b79120290ee5866136a0c4656e6999f06045 (diff) | |
parent | 4ca621a36016de1fbb5447e1c1de0b607ba94a7c (diff) |
Merge branch 'master' into patch-1
Conflicts:
locale/de_DE/LC_MESSAGES/messages.po
Diffstat (limited to 'js/viewfeed.js')
-rw-r--r-- | js/viewfeed.js | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/js/viewfeed.js b/js/viewfeed.js index c319a8ed0..f236e1f7c 100644 --- a/js/viewfeed.js +++ b/js/viewfeed.js @@ -56,7 +56,7 @@ function headlines_callback2(transport, offset, background, infscroll_req) { if (infscroll_req == false) { $("headlines-frame").scrollTop = 0; - Element.hide("floatingTitle"); + $("floatingTitle").style.visibility = "hidden"; $("floatingTitle").setAttribute("rowid", 0); $("floatingTitle").innerHTML = ""; } @@ -1532,7 +1532,7 @@ function cdmCollapseArticle(event, id, unmark) { if (row.offsetTop < $("headlines-frame").scrollTop) scrollToRowId(row.id); - Element.hide("floatingTitle"); + $("floatingTitle").style.visibility = "hidden"; $("floatingTitle").setAttribute("rowid", false); } @@ -2357,7 +2357,7 @@ function scrollToRowId(id) { var row = $(id); if (row) - $("headlines-frame").scrollTop = row.offsetTop; + $("headlines-frame").scrollTop = row.offsetTop - 4; } catch (e) { exception_error("scrollToRowId", e); @@ -2402,11 +2402,12 @@ function updateFloatingTitle(unread_only) { PluginHost.run(PluginHost.HOOK_FLOATING_TITLE, child); } - if (child.offsetTop < hf.scrollTop - header.offsetHeight && - child.offsetTop + child.offsetHeight - hf.scrollTop > header.offsetHeight) - Element.show("floatingTitle"); + $("floatingTitle").style.marginRight = hf.offsetWidth - child.offsetWidth + "px"; + if (header.offsetTop + header.offsetHeight < hf.scrollTop + $("floatingTitle").offsetHeight - 5 && + child.offsetTop + child.offsetHeight >= hf.scrollTop + $("floatingTitle").offsetHeight - 5) + $("floatingTitle").style.visibility = "visible"; else - Element.hide("floatingTitle"); + $("floatingTitle").style.visibility = "hidden"; return; |