mirror of
https://github.com/flynx/PortableMag.git
synced 2025-10-30 03:30:09 +00:00
more testing...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
bcfcb2c0d3
commit
a363984aaf
31
layout.html
31
layout.html
@ -127,17 +127,26 @@ $(document).ready(function(){
|
||||
function(k){console.log(k)}))
|
||||
|
||||
|
||||
//if(NAVIGATE_RELATIVE_TO_VISIBLE){
|
||||
$('.viewer')
|
||||
.on('scrollstop', function(evt){
|
||||
//log('scrollstop...')
|
||||
// XXX for some reason, on android, this sets the page but
|
||||
// does not actually scroll to it -- no animation and/or
|
||||
// .ScrollTo does notwork...
|
||||
//setCurrentPage()
|
||||
//limit_scroll()
|
||||
})
|
||||
//}
|
||||
var touching = false
|
||||
var t = null
|
||||
$('.viewer')
|
||||
.on('mousedown touchstart', function(){
|
||||
touching = true
|
||||
clearTimeout(t)
|
||||
})
|
||||
.on('mouseup touchend', function(){
|
||||
touching = false
|
||||
})
|
||||
.on('scrollstop', function(evt){
|
||||
//log('scrollstop...')
|
||||
// XXX for some reason, on android, this sets the page but
|
||||
// does not actually scroll to it -- no animation and/or
|
||||
// .ScrollTo does notwork...
|
||||
//limit_scroll()
|
||||
if(!touching){
|
||||
t = setTimeout(setCurrentPage, 100)
|
||||
}
|
||||
})
|
||||
|
||||
if(!NAVIGATE_RELATIVE_TO_VISIBLE){
|
||||
$('.viewer').css({overflow: 'hidden'})
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user