Permalink
Browse files

Commit 43bacc2 broke iscroll for some Android devices, check against …

…zoom boolean, not function

 Please enter the commit message for your changes. Lines starting
  • Loading branch information...
1 parent 9aa8f05 commit 8102a9c3489c623df17d37e58b61e17ae643cf49 Antti Tapaninen committed Dec 1, 2011
Showing with 9 additions and 7 deletions.
  1. +9 −7 src/iscroll.js
View
@@ -107,13 +107,7 @@ var m = Math,
onZoom: null,
onZoomEnd: null
};
- // Helpers FIX ANDROID BUG!
- // translate3d and scale doesn't work together!
- // Ignoring 3d ONLY WHEN YOU SET that.zoom
- if ( that.zoom && isAndroid ){
- trnOpen = 'translate(';
- trnClose = ')';
- }
+
// User defined options
for (i in options) that.options[i] = options[i];
@@ -127,6 +121,14 @@ var m = Math,
that.options.vScrollbar = that.options.vScroll && that.options.vScrollbar;
that.options.zoom = that.options.useTransform && that.options.zoom;
that.options.useTransition = hasTransitionEnd && that.options.useTransition;
+
+ // Helpers FIX ANDROID BUG!
+ // translate3d and scale doesn't work together!
+ // Ignoring 3d ONLY WHEN YOU SET that.options.zoom
+ if ( that.options.zoom && isAndroid ){
+ trnOpen = 'translate(';
+ trnClose = ')';
+ }
// Set some default styles
that.scroller.style[vendor + 'TransitionProperty'] = that.options.useTransform ? '-' + vendor.toLowerCase() + '-transform' : 'top left';

0 comments on commit 8102a9c

Please sign in to comment.