Fix Gallery not rescrolling
This commit is contained in:
parent
41ebd42722
commit
c13b3731b7
@ -8868,7 +8868,8 @@
|
||||
$.add(d.body, dialog);
|
||||
Gallery.thumbs.scrollTop = 0;
|
||||
Gallery.current.parentElement.scrollTop = 0;
|
||||
return Gallery.cb.open.call(this !== Gallery ? $("[href=" + this.href + "]", Gallery.thumbs) : Gallery.images[0]);
|
||||
Gallery.cb.open.call(this !== Gallery ? $("[href=" + this.href + "]", Gallery.thumbs) : Gallery.images[0]);
|
||||
return d.body.style.overflow = 'hidden';
|
||||
},
|
||||
generateThumb: function(file) {
|
||||
var double, thumb, title;
|
||||
@ -8915,8 +8916,7 @@
|
||||
Gallery.current.dataset.id = this.dataset.id;
|
||||
Gallery.url.href = Gallery.current.src = this.href;
|
||||
Gallery.url.download = Gallery.current.title = this.title;
|
||||
Gallery.current.parentElement.scrollTop = 0;
|
||||
return d.body.style.overflow = 'hidden';
|
||||
return Gallery.url.parentElement.scrollTop = 0;
|
||||
},
|
||||
prev: function() {
|
||||
return Gallery.cb.open.call(Gallery.images[+Gallery.current.dataset.id - 1]);
|
||||
|
||||
@ -8856,7 +8856,8 @@
|
||||
$.add(d.body, dialog);
|
||||
Gallery.thumbs.scrollTop = 0;
|
||||
Gallery.current.parentElement.scrollTop = 0;
|
||||
return Gallery.cb.open.call(this !== Gallery ? $("[href=" + this.href + "]", Gallery.thumbs) : Gallery.images[0]);
|
||||
Gallery.cb.open.call(this !== Gallery ? $("[href=" + this.href + "]", Gallery.thumbs) : Gallery.images[0]);
|
||||
return d.body.style.overflow = 'hidden';
|
||||
},
|
||||
generateThumb: function(file) {
|
||||
var double, thumb, title;
|
||||
@ -8903,8 +8904,7 @@
|
||||
Gallery.current.dataset.id = this.dataset.id;
|
||||
Gallery.url.href = Gallery.current.src = this.href;
|
||||
Gallery.url.download = Gallery.current.title = this.title;
|
||||
Gallery.current.parentElement.scrollTop = 0;
|
||||
return d.body.style.overflow = 'hidden';
|
||||
return Gallery.url.parentElement.scrollTop = 0;
|
||||
},
|
||||
prev: function() {
|
||||
return Gallery.cb.open.call(Gallery.images[+Gallery.current.dataset.id - 1]);
|
||||
|
||||
@ -64,6 +64,8 @@ Gallery =
|
||||
else
|
||||
Gallery.images[0]
|
||||
|
||||
d.body.style.overflow = 'hidden'
|
||||
|
||||
generateThumb: (file) ->
|
||||
title = ($ '.fileText a', file).textContent
|
||||
thumb = ($ '.fileThumb', file).cloneNode true
|
||||
@ -98,10 +100,9 @@ Gallery =
|
||||
if e
|
||||
e.preventDefault()
|
||||
Gallery.current.dataset.id = @dataset.id
|
||||
Gallery.url.href = Gallery.current.src = @href
|
||||
Gallery.url.href = Gallery.current.src = @href
|
||||
Gallery.url.download = Gallery.current.title = @title
|
||||
Gallery.current.parentElement.scrollTop = 0
|
||||
d.body.style.overflow = 'hidden'
|
||||
Gallery.url.parentElement.scrollTop = 0
|
||||
prev: ->
|
||||
Gallery.cb.open.call Gallery.images[+Gallery.current.dataset.id - 1]
|
||||
next: ->
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user