GitHub Issue | n/a |
Type | New Feature |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2014-04-08T20:30:30.000+0000 |
Affected Version/s | Release 3.0.0 |
Fix Version/s | 2014 Sprint 07, 2014 Sprint 07 SDK, Release 3.3.0 |
Components | iOS |
Labels | android, ios, module_scrollableview, qe-closed-3.3.0, qe-testadded, scrollableview |
Reporter | Martin Guillon |
Assignee | Vishal Duggal |
Created | 2012-10-08T13:10:44.000+0000 |
Updated | 2014-04-25T06:48:46.000+0000 |
* on android setCurrentPage sets the page with animation.
On ios it doesnt.
* movePrevious and moveNext should be implemented on iOS
* it would be nice to be able to choose if scrollToView, moveNext, movePrevious happen with animation
pull request https://github.com/appcelerator/titanium_mobile/pull/3146
updated test case
pull request https://github.com/appcelerator/titanium_mobile/pull/3146
Hi, I am coding an Android InfiniteScrollableView widget for a project. The widget works functionally in both directions, is optimised, is built using nothing but Ti framework code (unlike the other attempts I've found). The only thing stopping this from being finished is the bug referred to by this ticket. Setting the current page using setCurrentPage should definitely NOT use animation. scrollToView, moveNext & movePrevious SHOULD use animation. This is the most semantic solution. ----------------- There is a lot of community demand for a working InfiniteScrollableView widget so as an ultimatum I am offering to release the widget to the community along with an integration guide way ahead of schedule if this issue gets a 2013 fix date. Yes, this is cheeky on my part. I'm well aware ;)
Hi Ingo, I see that the description for this issue has changed to just point to iOS. Should the fact that Android animates on setCurrentPage have it's own ticket? Lee
[~lsdriscoll] So, to confirm for Android, it's the fact you can't choose to set the animation on or off that's the issue?
Hi Ingo. For my own project, yes that is the issue I have. Personally I don't think that there should be a parameter passed to enable animation, just the following api: |setCurrentPage|no animation| |scrollToView|with animation| |moveNext|with animation| |movePrevious|with animation| My reasoning for this is because I believe this to be the most semantic behaviour based on method names & it covers all developer requirements. moveNext & movePrevious would simply be shorthand for view.scrollToView(view.currentPage++) and view.scrollToView(view.currentPage--) respectively. IMHO As a complete fix for this ticket, I would implement consistent behaviour across iOs and android.
Test case for ticket in file. Expected behavior is as follows currentPage property - Non Animated Scroll moveNext,movePrevious,scrollToView methods - Animated Scroll
Pull pending against master https://github.com/appcelerator/titanium_mobile/pull/5543
Verified fix with below environment: Appc Studio: 3.3.0.201404211130 SDK build: 3.3.0.v20140422163054 acs: 1.0.14 npm: 1.3.2 alloy: 1.4.0-dev CLI: titanium-3.3.0-dev titanium-code-processor:1.1.1-beta1 Xcode: 5.1.1 Osx: Mavericks(10.9.2) Device: iPhone 5C( iOS 7.1) currentPage property - Non Animated Scroll moveNext,movePrevious,scrollToView methods - Animated Scroll as expected. Hence Closing the issue.