From a5e46e0f76ef85677a6e07592ffcc8cb49822835 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Wed, 16 May 2007 05:06:05 +0100 Subject: [PATCH] correctHeadlinesOffset: add opera remark --- viewfeed.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/viewfeed.js b/viewfeed.js index abf483e2..4942a25c 100644 --- a/viewfeed.js +++ b/viewfeed.js @@ -363,10 +363,14 @@ function correctHeadlinesOffset(id) { debug("Rtop: " + rel_offset_top + " Rbtm: " + rel_offset_bottom); debug("Vport: " + viewport); - + if (rel_offset_top <= 0 || rel_offset_top > viewport) { container.scrollTop = row.offsetTop; } else if (rel_offset_bottom > viewport) { + + /* doesn't properly work with Opera in some cases because + Opera fucks up element scrolling */ + container.scrollTop = row.offsetTop + row.offsetHeight - viewport; } -- 2.39.5