Don't try to update the read posts until all posts are parsed.
This commit is contained in:
parent
b656e6d690
commit
108920c536
@ -54,16 +54,16 @@ Unread =
|
|||||||
defaultValue: 0
|
defaultValue: 0
|
||||||
Unread.readCount = 0
|
Unread.readCount = 0
|
||||||
Unread.readCount++ for ID in @posts.keys when +ID <= Unread.lastReadPost
|
Unread.readCount++ for ID in @posts.keys when +ID <= Unread.lastReadPost
|
||||||
$.one d, '4chanXInitFinished', Unread.ready
|
$.one d, '4chanXInitFinished', Unread.ready
|
||||||
$.on d, 'ThreadUpdate', Unread.onUpdate
|
$.on d, 'ThreadUpdate', Unread.onUpdate
|
||||||
$.on d, 'scroll visibilitychange', Unread.read
|
|
||||||
$.on d, 'visibilitychange', Unread.setLine if Conf['Unread Line']
|
|
||||||
|
|
||||||
ready: ->
|
ready: ->
|
||||||
Unread.setLine true
|
Unread.setLine true
|
||||||
Unread.read()
|
Unread.read()
|
||||||
Unread.update()
|
Unread.update()
|
||||||
Unread.scroll() if Conf['Scroll to Last Read Post']
|
Unread.scroll() if Conf['Scroll to Last Read Post']
|
||||||
|
$.on d, 'scroll visibilitychange', Unread.read
|
||||||
|
$.on d, 'visibilitychange', Unread.setLine if Conf['Unread Line']
|
||||||
|
|
||||||
positionPrev: ->
|
positionPrev: ->
|
||||||
if Unread.position then Unread.position.prev else Unread.order.last
|
if Unread.position then Unread.position.prev else Unread.order.last
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user