javascript - $ionicScrollDelegate.scrollTop freezing the page scroll -
i have app have added functionality scroll user top if user clicks on status bar , in order achieve have used following code
.run(["$ionicscrolldelegate", "$ionicplatform", "$timeout", function($ionicscrolldelegate, $ionicplatform, $timeout) { $ionicplatform.ready(function() { if (window.cordova && ionic.platform.isios()) { window.addeventlistener("statustap", function() { $ionicscrolldelegate.scrolltop([true]); }); } }); }])
when click status bar code works expected after not allow me scroll pages manually , stucks
i believe using android phone test. if android i'm pretty sure there have bug using animation auto-scroll. have try remove animation delete 'true' value on function? ex:
$ionicscrolldelegate.scrolltop(true);
to
$ionicscrolldelegate.scrolltop();
try it.. hope helps you. ios working fine animation scroll not android. sad.. :(
update (solution):
okay found solution.. seem need set 'jsscrolling: true' instead of default 'jsscrolling: false' android.
please modified/edit on 'ionic-angular.js'
hope helps others :)
Comments
Post a Comment