Implement #673
Conflicts: builds/appchan-x.user.js builds/crx/script.js src/General/Config.coffee src/Images/Gallery.coffee
This commit is contained in:
parent
05ffeb048a
commit
0912bfb98d
@ -448,13 +448,15 @@ Config =
|
|||||||
'Hide Thumbnails': [
|
'Hide Thumbnails': [
|
||||||
false
|
false
|
||||||
]
|
]
|
||||||
# Fit Width =/= Fit width
|
'Fit Width': [ # 'Fit width' (lowercase W) belongs to Image Expansion. Engine limitations, heh.
|
||||||
'Fit Width': [
|
|
||||||
true
|
true
|
||||||
]
|
]
|
||||||
'Fit Height': [
|
'Fit Height': [
|
||||||
true
|
true
|
||||||
]
|
]
|
||||||
|
'Scroll to Post': [
|
||||||
|
true
|
||||||
|
]
|
||||||
'Slide Delay': [
|
'Slide Delay': [
|
||||||
5.0
|
5.0
|
||||||
]
|
]
|
||||||
|
|||||||
@ -165,6 +165,13 @@ Gallery =
|
|||||||
# Center selected thumbnail
|
# Center selected thumbnail
|
||||||
nodes.thumbs.scrollTop = @offsetTop + @offsetHeight/2 - nodes.thumbs.clientHeight/2
|
nodes.thumbs.scrollTop = @offsetTop + @offsetHeight/2 - nodes.thumbs.clientHeight/2
|
||||||
|
|
||||||
|
# Scroll to post
|
||||||
|
try
|
||||||
|
if Conf['Scroll to Post'] and post = (post = g.posts[file.dataset.post])?.nodes.root
|
||||||
|
Header.scrollTo post
|
||||||
|
catch err
|
||||||
|
console.log err
|
||||||
|
|
||||||
image: (e) ->
|
image: (e) ->
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
e.stopPropagation()
|
e.stopPropagation()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user