mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
feat(scrollView): better deceleration for scroll view on iOS
This commit is contained in:
10
js/angular/controller/scrollController.js
vendored
10
js/angular/controller/scrollController.js
vendored
@@ -39,7 +39,15 @@ function($scope, scrollViewOptions, $timeout, $window, $$scrollValueCache, $loca
|
||||
|
||||
if (!angular.isDefined(scrollViewOptions.bouncing)) {
|
||||
ionic.Platform.ready(function() {
|
||||
scrollView.options.bouncing = !ionic.Platform.isAndroid();
|
||||
scrollView.options.bouncing = true;
|
||||
|
||||
if(ionic.Platform.isAndroid()) {
|
||||
// No bouncing by default on Android
|
||||
scrollView.options.bouncing = false;
|
||||
// Faster scroll decel
|
||||
scrollView.options.deceleration = 0.95;
|
||||
} else {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user