{ "id": "90821", "key": "TIMOB-8875", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "13271", "description": "Release 2.1.0", "name": "Release 2.1.0", "archived": false, "released": true, "releaseDate": "2012-06-29" }, { "id": "13401", "description": "Sprint 2012-09 Core", "name": "Sprint 2012-09 Core", "archived": true, "released": true, "releaseDate": "2012-05-06" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2012-07-11T00:31:02.000+0000", "created": "2012-04-24T14:56:43.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "core", "module_scrollview", "qe-testadded", "regression" ], "versions": [ { "id": "13273", "description": "Release 2.0.2", "name": "Release 2.0.2", "archived": false, "released": true, "releaseDate": "2012-05-31" } ], "issuelinks": [ { "id": "22084", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "103350", "key": "TIMOB-11477", "fields": { "summary": "iOS: Scrollview - App crash on launch ", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2012-10-17T22:12:39.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "When views are added to another view which has width = Ti.UI.SIZE set, some of the child views are not displayed.\r\nThis worked correctly in 1.8.2.\r\nSee attached screenshot.\r\n\r\nh4.Steps to reproduce\r\nStep 1: run the code below on 2.0.1.GA2\r\nStep 2: notice that you can only see the red views that are fully on the screen\r\nStep 3: scroll to the side and notice that the rest of the red views are not there\r\nStep 4: replace Ti.UI.SIZE with 2000 and run it again\r\nStep 5: notice that all of the red views are displayed as expected\r\n\r\nh4. Prove this is a regression;\r\nStep 1: \"width = 'auto'\" in 1.8.2 is the same as \"width = Ti.UI.SIZE\" in 2.0.1 (they both shrink to the size of their children)\r\nStep 2: in the code below comment out \"width: Ti.UI.SIZE,\" and use \"width: 'auto',\" instead\r\nStep 3: run this edited code with 1.8.2 and notice that all of the red views are displayed as expected (see screenshot)\r\n\r\n{code:js}\r\nvar win = Ti.UI.createWindow({backgroundColor:'white'});\r\nwin.open();\r\n\r\nvar scrollView = Ti.UI.createScrollView({\r\n\tcontentWidth: 2000,\r\n\tbackgroundColor: 'black',\r\n\tlayout: 'horizontal'\r\n});\r\nwin.add(scrollView);\r\n\r\nvar view1 = Ti.UI.createView({\r\n\tbackgroundColor: 'blue',\r\n\theight: 400,\r\n\t// for 2.0\r\n\twidth: Ti.UI.SIZE,\r\n\t// for 1.8\r\n\t// width: 'auto',\r\n\tlayout: 'horizontal'\r\n});\r\nscrollView.add(view1);\r\n\r\nfor(var i = 0, j = 20; i < j; i++){\r\n\tview1.add(Ti.UI.createView({\r\n\t\tbackgroundColor: 'red',\r\n\t\twidth: 100,\r\n\t\theight: 400,\r\n\t\tleft: 40\r\n\t}));\r\n}\r\n{code}", "attachment": [ { "id": "27365", "filename": "2.0.1.broken.jpg", "author": { "name": "jalter", "key": "jalter", "displayName": "Jon Alter", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-04-24T14:56:43.000+0000", "size": 72652, "mimeType": "image/jpeg" } ], "flagged": false, "summary": "iOS: View SIZE - some child views are not shown when view.width = Ti.UI.SIZE", "creator": { "name": "jalter", "key": "jalter", "displayName": "Jon Alter", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "jalter", "key": "jalter", "displayName": "Jon Alter", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "TiSDK 2.0.1.GA2\r\niOS Simulator 4.3\r\niOS Simulator 5.0", "comment": { "comments": [ { "id": "192855", "author": { "name": "mstepanov", "key": "mstepanov", "displayName": "Max Stepanov", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Fixed by PR 2073 for TIMOB-8773 TIMOB-8775", "updateAuthor": { "name": "mstepanov", "key": "mstepanov", "displayName": "Max Stepanov", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-04-26T16:55:05.000+0000", "updated": "2012-04-26T16:55:05.000+0000" }, { "id": "199138", "author": { "name": "mpettiford", "key": "mpettiford", "displayName": "Michael Pettiford", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Closing issue\r\n\r\nTested with Ti Studio build 2.1.0.201206172244\r\nTi Mobile SDK 2.1.0.v20120618154152 hash r7830c03d\r\nOSX Lion 10.7.3\r\niPhone 4S OS 5.1\r\n\r\nThe expected behavior is shown", "updateAuthor": { "name": "mpettiford", "key": "mpettiford", "displayName": "Michael Pettiford", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-06-19T11:13:06.000+0000", "updated": "2012-06-19T11:13:06.000+0000" }, { "id": "202529", "author": { "name": "amittal", "key": "amittal", "displayName": "Anshu Mittal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Reopening to update labels", "updateAuthor": { "name": "amittal", "key": "amittal", "displayName": "Anshu Mittal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-07-11T00:30:35.000+0000", "updated": "2012-07-11T00:30:35.000+0000" } ], "maxResults": 3, "total": 3, "startAt": 0 } } }