Native Scrolling: Android Testers Wanted

There you go https://gist.github.com/415dd500d27ddf056f74

1 Like

@perry Just purchased a Galaxy S5 and this is not an issue on there. Scrolling is functional. So this is only an iOS problem.

However, one Android bug I did notice/expect was when the you navigate back with the S5 the scroll position is forgotten. Which is expected since that feature relies on a JS scrolling variable.

Were you able to reproduce this issue on iOS? Would you like me to open up a github issue?

@gmustudent yeah, it requires a working scrollDelegate for native scrolling. The form input bugs are related to that too. Iā€™m working on that right now.

3 Likes

I do have one error logging in the console ā€™ Uncaught TypeError: Cannot read property ā€˜freezeā€™ of nullā€™ referenced in the Ionic.bundle.js file from the nightly 1060. for ionic.views.ListView.ionic.views.View.inherit._handleEndDrag. This is running from the ionic serve --lab in Chrome if that matters.

On the device, Samsung Galaxy S5 running Android 4.4.4, I canā€™t scroll an ion-list directive and the collection-repeat doesnā€™t render as reported previously. Also, the scroll bar is always present on the app. I might have overlooked any layout fixes if theyā€™ve been mentioned on this thread. Having trouble uploading image to the thread so hereā€™s a link to an image showing the scroll bar present when there isnā€™t room for scrolling. https://drive.google.com/file/d/0BzU_gbqznVQdeGVvTkNiQl9xRDQ/view?usp=sharing

1 Like

How to check CPU usage on ionic app? (to compare with or without scroll native)

You can activate on developer options (depending on your android version, not sure if all versions have this option).

Or you can use chrome remote inspect to check frame rate too.

Hi Perry Scroll seems to be much better, i just tried in my sample app and tested in Nexus 5 with Android L, but i see a delay in scroll to start.

When i scroll on my device a sec later the list starts scrolling. (Using ng-repeat for list items!)

Thanks for the file! However the code looks incomplete at the bottom of file. :frowning:

Same issue here, canā€™t scroll on lists and the chrome inspect of the app display the ā€œCannot read property ā€˜freezeā€™ of nullā€ā€¦

Any ideas @perry?

1 Like

Yeah, itā€™s tap.js checking scrollView.js to see if the user is actively scrolling. Iā€™m working on creating a native version of scrollView.js in a WIP branch for the parts of Ionic thatā€™s not practical to make them stand on their own. Itā€™s coming along well, but needs some cleaning up and unit tests.

1 Like

Cant use native scroll with ion-side-menus

great catch, thank you

I made this update in my app, here is what I get.

PS1: I completely removed collection-repeat to test it.

  1. $scrollDelegate.scrollTop doesnā€™t work :confused:
  2. Sometimes while scrolling if I start scrolling a bit to the left the content doesnā€™t stay fixed, the content moves like left: -100 pixels ou of view.
  3. refresher is annoying, sometimes it appears sometimes disappear, it works, but not well.
  4. infinite-scroll works well.

To get my app to work with Native Scroll I just need improvements in $scrollDelegate, refresher and this weird behaviour of while scrolling the content start moving to the left of the screen, out of view.

Thanks :slight_smile:

Sorry, didnā€™t notice that. Hereā€™s the link with the full file http://inft.ly/UkXZ5NB

1 Like

Native scrolling is MUCH better, iā€™ll notify you for any strange behaviours.

2 Likes

Thank Perry~!

I tired in my app, +Crosswalk, scrolling performance is much better, but I got the similar issues as other guys,
a. delay when scroll starts - minor issue
b. while scrolling, the whole view width grows several pixels - some elements in my app float right, this issue influences too much ui experienceā€¦

Update: after investigated the issue b, the reason is I used class=ā€˜paddingā€™ in ion-content, when ion-content has padding, and we PTR, the ion-content got extended.
Now I have to remove the padding, and use margin for ion-content children.

Hope the info. helps and a fix can be in next patch. Thanks again.

1 Like

Ionic Version: Ionic, v1.0.0-beta.14-nightly-1116

I updated Ionic to use the updates to collection-repeat, with the native scrolling enabled the following error is logged, which I did not notice prior to this nightly version when testing.

image

@perry Howā€™s going the fixes in $scrollDelegate ?
You now when the new changes are gone to be available?

Thanks!

I add the same exact error:
Error: [$compile:ctreq] Controller ā€˜$ionicScrollā€™, required by directive ā€˜collectionRepeatā€™, canā€™t be found!

I just added this:

if(ionic.Platform.isAndroid())
         $ionicConfigProvider.scrolling.jsScrolling(false);

When I revert, this works.

Did I missed something important ?

@Mik378 - so you are saying when you add the native scrolling you have the error, if so thatā€™s my issue. Using javascript scrolling there is no error. Sorry, just not following you message very clearly. :slight_smile:

1 Like