From a6dc7262fc05eef785bf86bcae553353f5ce364b Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Thu, 18 Apr 2013 19:19:54 +0200 Subject: [PATCH] Scroll to unread posts on window load instead of dom load. --- src/features.coffee | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/features.coffee b/src/features.coffee index f731c64bf..212b921c5 100644 --- a/src/features.coffee +++ b/src/features.coffee @@ -3759,8 +3759,9 @@ Unread = $.on d, 'ThreadUpdate', Unread.onUpdate $.on d, 'scroll visibilitychange', Unread.read $.on d, 'visibilitychange', Unread.setLine if Conf['Unread Line'] + $.on window, 'load', Unread.scroll if Conf['Scroll to Last Read Post'] - return unless Conf['Scroll to Last Read Post'] + scroll: -> # Let the header's onload callback handle it. return if (hash = location.hash.match /\d+/) and hash[0] of @posts if Unread.posts.length