summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2018-12-01 22:12:36 +0300
committerAndrew Dolgov <[email protected]>2018-12-01 22:12:36 +0300
commit6c110c1ceb0323ca31a1e914586e9d4e2d5ed17a (patch)
tree93af8d3a04f45836beef5003c8fe16ee1a3eb89b /js
parentde9509cd31d63b036f63fc56697e018263e52eda (diff)
headlines scroll handler: don't autoselect anything if feed was just opened
Diffstat (limited to 'js')
-rwxr-xr-xjs/viewfeed.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/js/viewfeed.js b/js/viewfeed.js
index 01e5cb325..ea4bd9659 100755
--- a/js/viewfeed.js
+++ b/js/viewfeed.js
@@ -435,8 +435,10 @@ const Headlines = {
if (App.isCombinedMode()) {
Headlines.updateFloatingTitle();
- // set topmost child in the buffer as active
- if (getInitParam("cdm_expanded") && getInitParam("cdm_auto_catchup") == 1) {
+ // set topmost child in the buffer as active, but not if we're at the beginning (to prevent auto marking
+ // first article as read all the time)
+ if ($("headlines-frame").scrollTop != 0 &&
+ getInitParam("cdm_expanded") && getInitParam("cdm_auto_catchup") == 1) {
const rows = $$("#headlines-frame > div[id*=RROW]");