From 58a80da50e3b3e003fd2514ec3b57bb667df2c09 Mon Sep 17 00:00:00 2001 From: Max Lynch Date: Thu, 17 Dec 2015 08:33:02 -0600 Subject: [PATCH] remove float parsing on refresher --- js/angular/controller/refresherController.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/js/angular/controller/refresherController.js b/js/angular/controller/refresherController.js index 85fd8d0b4aa..50a5b8bbb2b 100644 --- a/js/angular/controller/refresherController.js +++ b/js/angular/controller/refresherController.js @@ -89,7 +89,7 @@ IonicModule } //if this is a new drag, keep track of where we start if (startY === null) { - startY = Math.floor(e.touches[0].screenY); + startY = e.touches[0].screenY; } // kitkat fix for touchcancel events http://updates.html5rocks.com/2014/05/A-More-Compatible-Smoother-Touch @@ -99,7 +99,7 @@ IonicModule } // how far have we dragged so far? - deltaY = Math.floor(e.touches[0].screenY) - startY; + deltaY = e.touches[0].screenY - startY; // if we've dragged up and back down in to native scroll territory if (deltaY - dragOffset <= 0 || scrollParent.scrollTop !== 0) { @@ -110,7 +110,7 @@ IonicModule } if (isDragging) { - nativescroll(scrollParent, Math.floor(deltaY - dragOffset) * -1); + nativescroll(scrollParent, deltaY - dragOffset * -1); } // if we're not at overscroll 0 yet, 0 out @@ -135,7 +135,7 @@ IonicModule isDragging = true; // overscroll according to the user's drag so far - overscroll(Math.floor((deltaY - dragOffset) / 3)); + overscroll((deltaY - dragOffset) / 3)); // update the icon accordingly if (!activated && lastOverscroll > ptrThreshold) {