@@ -45,7 +45,7 @@ IonicModule
45
45
screenY : e . screenY
46
46
} ] ;
47
47
// Mouse needs this
48
- startY = parseInt ( e . touches [ 0 ] . screenY , 10 ) ;
48
+ startY = Math . floor ( e . touches [ 0 ] . screenY ) ;
49
49
}
50
50
51
51
function handleTouchend ( ) {
@@ -89,7 +89,7 @@ IonicModule
89
89
}
90
90
//if this is a new drag, keep track of where we start
91
91
if ( startY === null ) {
92
- startY = parseInt ( e . touches [ 0 ] . screenY , 10 ) ;
92
+ startY = Math . floor ( e . touches [ 0 ] . screenY ) ;
93
93
}
94
94
95
95
// kitkat fix for touchcancel events http://updates.html5rocks.com/2014/05/A-More-Compatible-Smoother-Touch
@@ -99,7 +99,7 @@ IonicModule
99
99
}
100
100
101
101
// how far have we dragged so far?
102
- deltaY = parseInt ( e . touches [ 0 ] . screenY , 10 ) - startY ;
102
+ deltaY = Math . floor ( e . touches [ 0 ] . screenY ) - startY ;
103
103
104
104
// if we've dragged up and back down in to native scroll territory
105
105
if ( deltaY - dragOffset <= 0 || scrollParent . scrollTop !== 0 ) {
@@ -110,7 +110,7 @@ IonicModule
110
110
}
111
111
112
112
if ( isDragging ) {
113
- nativescroll ( scrollParent , parseInt ( deltaY - dragOffset , 10 ) * - 1 ) ;
113
+ nativescroll ( scrollParent , Math . floor ( deltaY - dragOffset ) * - 1 ) ;
114
114
}
115
115
116
116
// if we're not at overscroll 0 yet, 0 out
@@ -135,7 +135,7 @@ IonicModule
135
135
136
136
isDragging = true ;
137
137
// overscroll according to the user's drag so far
138
- overscroll ( parseInt ( ( deltaY - dragOffset ) / 3 , 10 ) ) ;
138
+ overscroll ( Math . floor ( ( deltaY - dragOffset ) / 3 ) ) ;
139
139
140
140
// update the icon accordingly
141
141
if ( ! activated && lastOverscroll > ptrThreshold ) {
@@ -231,7 +231,7 @@ IonicModule
231
231
// fraction based on the easing method
232
232
easedT = easeOutCubic ( time ) ;
233
233
234
- overscroll ( parseInt ( ( easedT * ( Y - from ) ) + from , 10 ) ) ;
234
+ overscroll ( Math . floor ( ( easedT * ( Y - from ) ) + from ) ) ;
235
235
236
236
if ( time < 1 ) {
237
237
ionic . requestAnimationFrame ( scroll ) ;
0 commit comments