Improve auto-fullscreen delay #625
This commit is contained in:
parent
5c1ee46a21
commit
89b4f56160
@ -309,11 +309,11 @@ view.photo = {
|
|||||||
$('body').css('overflow', 'hidden')
|
$('body').css('overflow', 'hidden')
|
||||||
|
|
||||||
// Fullscreen
|
// Fullscreen
|
||||||
var timeout
|
let timeout = null
|
||||||
$(document).bind('mousemove', function() {
|
$(document).bind('mousemove', function() {
|
||||||
clearTimeout(timeout)
|
clearTimeout(timeout)
|
||||||
header.show()
|
header.show()
|
||||||
timeout = setTimeout(header.hide, 1000)
|
timeout = setTimeout(header.hide, 2500)
|
||||||
})
|
})
|
||||||
|
|
||||||
lychee.animate(lychee.imageview, 'fadeIn')
|
lychee.animate(lychee.imageview, 'fadeIn')
|
||||||
@ -331,8 +331,7 @@ view.photo = {
|
|||||||
$('body').css('overflow', 'auto')
|
$('body').css('overflow', 'auto')
|
||||||
|
|
||||||
// Disable Fullscreen
|
// Disable Fullscreen
|
||||||
$(document)
|
$(document).unbind('mousemove')
|
||||||
.unbind('mousemove')
|
|
||||||
|
|
||||||
// Hide Photo
|
// Hide Photo
|
||||||
lychee.animate(lychee.imageview, 'fadeOut')
|
lychee.animate(lychee.imageview, 'fadeOut')
|
||||||
|
Loading…
Reference in New Issue
Block a user