{ "id": "130282", "key": "AC-1312", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "5", "description": "All attempts at reproducing this issue failed, or not enough information was available to reproduce the issue. Reading the code produces no clues as to why this behavior would occur. If more information appears later, please reopen the issue.", "name": "Cannot Reproduce" }, "resolutiondate": "2014-05-14T05:02:26.000+0000", "created": "2014-05-12T14:30:03.000+0000", "labels": [ "ios" ], "versions": [], "issuelinks": [], "assignee": { "name": "ragrawal", "key": "ragrawal", "displayName": "Ritu Agrawal", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2016-03-08T07:37:43.000+0000", "status": { "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.", "name": "Resolved", "id": "5", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "14548", "name": "Titanium SDK & CLI", "description": "Please enter tickets related to the MobileSDK here." } ], "description": "On iOS, when I have my scrollable view on my screen in landscape, it doesn't set the current page sometimes of the scrollable view when the 'scrollend' event is fired. Every 4 seconds I let my scrollableview scroll to the next view. \r\n\r\nThis is done by executing scrollableView.scrollToView(scrollableView.currentPage+1).\r\n\r\nBefore executing scrollToView the current page is for example 2, when the scrollend event is fired, the current page is still 2, by checking the e.currentPage of the event.\r\n\r\nLog:\r\n[INFO] : Before Scroll - CurPag: 0\r\n[INFO] : Scrollend - CurPag: 1\r\n[INFO] : Before Scroll - CurPag: 1\r\n[INFO] : Scrollend - CurPag: 2\r\n[INFO] : Before Scroll - CurPag: 2:\r\n[INFO] : Scrollend - CurPag: 2", "attachment": [], "flagged": false, "summary": "ScrollableView scrollend doesn't change currentPage in landscape mode", "creator": { "name": "Serfenia", "key": "serfenia", "displayName": "Patrick van Vuuren", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "Serfenia", "key": "serfenia", "displayName": "Patrick van Vuuren", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "iOS", "comment": { "comments": [ { "id": "304350", "author": { "name": "Serfenia", "key": "serfenia", "displayName": "Patrick van Vuuren", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Also when scrolling to the end, when I have 5 views attached, I can scroll to page 5 (4 as index), but the currentPage attribute remains a maximum of 4 (3 as index). Has this something to do with the width of the views?", "updateAuthor": { "name": "Serfenia", "key": "serfenia", "displayName": "Patrick van Vuuren", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-05-12T14:41:09.000+0000", "updated": "2014-05-12T14:41:09.000+0000" }, { "id": "304399", "author": { "name": "ragrawal", "key": "ragrawal", "displayName": "Ritu Agrawal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Please provide a simple runnable test case and we would be happy to investigate the issue further.", "updateAuthor": { "name": "ragrawal", "key": "ragrawal", "displayName": "Ritu Agrawal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-05-12T17:29:37.000+0000", "updated": "2014-05-12T17:29:37.000+0000" }, { "id": "304543", "author": { "name": "Serfenia", "key": "serfenia", "displayName": "Patrick van Vuuren", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Hey Ritu,\r\n\r\nWell I would love to, but when running a simple test case (See below, Alloy), it functions correct.\r\n\r\nfunction doClick(e) { \r\n alert($.label.text);\r\n}\r\n \r\n(function(){\r\n var view1 = Ti.UI.createView({ backgroundColor: 'red' });\r\n var view2 = Ti.UI.createView({ backgroundColor: 'green' });\r\n var view3 = Ti.UI.createView({ backgroundColor: 'blue' });\r\n var view4 = Ti.UI.createView({ backgroundColor: 'yellow' });\r\n \r\n var scrollableView = Ti.UI.createScrollableView({\r\n showPagingControl: false,\r\n left:\"1%\",\r\n top:\"7%\",\r\n width:\"98%\",\r\n height:\"44%\",\r\n views: [\r\n view1,\r\n view2,\r\n view3,\r\n view4\r\n ]\r\n });\r\n scrollableView.addEventListener('scrollend', function (e) {\r\n Ti.API.info('direct: ' + e.currentPage + ' : ' + JSON.stringify(e));\r\n Ti.API.info('scrollableView: ' + scrollableView.currentPage);\r\n Ti.API.info('scrollableView get: ' + scrollableView.getCurrentPage());\r\n Ti.API.info('source: ' + e.source.currentPage);\r\n Ti.API.info('source get: ' + e.source.getCurrentPage());\r\n $.label.setText(e.currentPage + ' : ' + e.view.backgroundColor);\r\n });\r\n scrollableView.addEventListener('scroll', function (e) {\r\n Ti.API.info('direct: ' + e.currentPage + ' : ' + JSON.stringify(e));\r\n });\r\n $.container.add(scrollableView);\r\n})();\r\n \r\n$.container.open();\r\n\r\nThis topic on the Q&A page explains a bit the issue.\r\nhttp://developer.appcelerator.com/question/147647/ios-scrollableview-currentpage-index-issue\r\n\r\nI've tried their test cases and they work fine in a new mobile application.\r\nSo, at the moment, I cannot reproduce the issue with a simple test case.", "updateAuthor": { "name": "Serfenia", "key": "serfenia", "displayName": "Patrick van Vuuren", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-05-13T07:57:22.000+0000", "updated": "2014-05-13T07:57:22.000+0000" }, { "id": "304754", "author": { "name": "ragrawal", "key": "ragrawal", "displayName": "Ritu Agrawal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Resolving this ticket as you cannot reproduce it with a simple test case. Let us know if you put together a test case to demonstrate this issue and we would be happy to reopen this ticket.", "updateAuthor": { "name": "ragrawal", "key": "ragrawal", "displayName": "Ritu Agrawal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-05-14T05:02:26.000+0000", "updated": "2014-05-14T05:02:26.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }