mirror of
https://github.com/flynx/PortableMag.git
synced 2025-12-23 20:11:46 +00:00
another attempt to tame the scroll...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
d4eebe7c05
commit
1812b5b91b
10
layout.html
10
layout.html
@ -133,16 +133,6 @@ $(document).ready(function(){
|
|||||||
window._cur_page = 0
|
window._cur_page = 0
|
||||||
|
|
||||||
$('.viewer')
|
$('.viewer')
|
||||||
.on('scroll', function(){
|
|
||||||
var c = getPageNumber()
|
|
||||||
if(_cur_page != c && scroll_state == 'touching'){
|
|
||||||
log('page: '+c)
|
|
||||||
//setCurrentPage(c)
|
|
||||||
$('.current.page').removeClass('current')
|
|
||||||
$($('.page')[c]).addClass('current')
|
|
||||||
_cur_page = c
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.on('mousedown touchstart', function(){
|
.on('mousedown touchstart', function(){
|
||||||
log('touching...')
|
log('touching...')
|
||||||
scroll_state = 'touching'
|
scroll_state = 'touching'
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user